Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 33 additions & 1 deletion src/apis/Style.res
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,29 @@ type filter

external unsafeFilter: {..} => filter = "%identity"

type blendMode = [
| #normal
| #multiply
| #screen
| #overlay
| #darken
| #lighten
| #"color-dodge"
| #"color-burn"
| #"hard-light"
| #"soft-light"
| #difference
| #exclusion
| #hue
| #saturation
| #color
| #luminosity
]

type isolation = [#auto | #isolate]

type outlineStyle = [#solid | #dotted | #dashed]

type resizeMode = [#cover | #contain | #stretch | #repeat | #center]

type fontStyle = [#normal | #italic]
Expand Down Expand Up @@ -138,7 +161,9 @@ type backfaceVisibility = [#visible | #hidden]

type borderStyle = [#solid | #dotted | #dashed]

type display = [#none | #flex]
type display = [#none | #flex | #contents]

type boxSizing = [#"border-box" | #"content-box"]

type overflow = [#visible | #hidden | #scroll]

Expand Down Expand Up @@ -230,6 +255,7 @@ type flexStyle = {
columnGap?: size,
direction?: direction,
display?: display,
boxSizing?: boxSizing,
end?: size,
flex?: float,
flexBasis?: margin,
Expand Down Expand Up @@ -330,8 +356,14 @@ type viewCoreStyle = {
borderTopStartRadius?: float,
boxShadow?: array<boxShadow>,
filter?: array<filter>,
mixBlendMode?: blendMode,
isolation?: isolation,
elevation?: float,
opacity?: float,
outlineColor?: Color.t,
outlineOffset?: float,
outlineStyle?: outlineStyle,
outlineWidth?: float,
}

// Text Style Props (https://reactnative.dev/docs/text-style-props)
Expand Down
34 changes: 33 additions & 1 deletion src/apis/Style.resi
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,29 @@ type filter

external unsafeFilter: {..} => filter = "%identity"

type blendMode = [
| #normal
| #multiply
| #screen
| #overlay
| #darken
| #lighten
| #"color-dodge"
| #"color-burn"
| #"hard-light"
| #"soft-light"
| #difference
| #exclusion
| #hue
| #saturation
| #color
| #luminosity
]

type isolation = [#auto | #isolate]

type outlineStyle = [#solid | #dotted | #dashed]

type resizeMode = [#cover | #contain | #stretch | #repeat | #center]

type fontStyle = [#normal | #italic]
Expand Down Expand Up @@ -126,7 +149,9 @@ type backfaceVisibility = [#visible | #hidden]

type borderStyle = [#solid | #dotted | #dashed]

type display = [#none | #flex]
type display = [#none | #flex | #contents]

type boxSizing = [#"border-box" | #"content-box"]

type overflow = [#visible | #hidden | #scroll]

Expand Down Expand Up @@ -218,6 +243,7 @@ type flexStyle = {
columnGap?: size,
direction?: direction,
display?: display,
boxSizing?: boxSizing,
end?: size,
flex?: float,
flexBasis?: margin,
Expand Down Expand Up @@ -318,8 +344,14 @@ type viewCoreStyle = {
borderTopStartRadius?: float,
boxShadow?: array<boxShadow>,
filter?: array<filter>,
mixBlendMode?: blendMode,
isolation?: isolation,
elevation?: float,
opacity?: float,
outlineColor?: Color.t,
outlineOffset?: float,
outlineStyle?: outlineStyle,
outlineWidth?: float,
}

// Text Style Props (https://reactnative.dev/docs/text-style-props)
Expand Down
Loading