git.iko.soy/rowtype-yoga/purescript-fahrtwind
on main help sign in
src/Fahrtwind/Animation.purs+1−1
since splitsnapshots
unifiedsplit
@@ -48,4 +48,4 @@ headShakeAnimationName =
48 , "31.5%": E.css { transform: E.str " translateX(-3px) rotateY(-5deg)" }
48 , "31.5%": E.css { transform: E.str " translateX(-3px) rotateY(-5deg)" }
49 , "43.5%": E.css { transform: E.str " translateX(2px) rotateY(3deg)" }
49 , "43.5%": E.css { transform: E.str " translateX(2px) rotateY(3deg)" }
50 , "50%": E.css { transform: E.str "translateX(0)" }
50 , "50%": E.css { transform: E.str "translateX(0)" }
51− }
51+ }
src/Fahrtwind/Style.purs+3−3
@@ -36,11 +36,11 @@ module Fahrtwind.Style
36
36
37import Fahrtwind.Style.BlendMode (backgroundBlendMode, mixBlendMode)
37import Fahrtwind.Style.BlendMode (backgroundBlendMode, mixBlendMode)
38import Fahrtwind.Style.BlendMode.Types (BlendMode(..), blendModeToStyleProperty)
38import Fahrtwind.Style.BlendMode.Types (BlendMode(..), blendModeToStyleProperty)
39−import Fahrtwind.Style.Border (border, borderBottom, borderCol, borderCol', borderLeft, borderNone, borderRight, borderSolid, borderTop, boxSizingBorderBox, boxSizingContentBox, rounded, rounded2xl, rounded3xl, roundedDefault, roundedFull, roundedLg, roundedMd, roundedNone, roundedSm, roundedXl)
39+import Fahrtwind.Style.Border (border, borderBottom, borderCol, borderCol', borderLeft, borderNone, borderRight, borderSolid, borderTop, boxSizingBorderBox, boxSizingContentBox, rounded, rounded2xl, rounded3xl, roundedDefault, roundedFull, roundedLg, roundedMd, roundedNone, roundedSm, roundedXl, borderGradient)
40import Fahrtwind.Style.BoxModel (m', mB, mB', mL, mL', mR, mR', mT, mT', mX, mX', mXAuto, mXY, mY, mY', p', pB, pB', pL, pL', pR, pR', pT, pT', pX, pX', pXY, pY, pY')
40import Fahrtwind.Style.BoxModel (m', mB, mB', mL, mL', mR, mR', mT, mT', mX, mX', mXAuto, mXY, mY, mY', p', pB, pB', pL, pL', pR, pR', pT, pT', pX, pX', pXY, pY, pY')
41import Fahrtwind.Style.BoxShadow (mkShadow, shadow, shadow', shadowDefault, shadowDefaultCol, shadowLg, shadowLgCol, shadowMd, shadowMdCol, shadowSm, shadowSmCol, shadowXl, shadowXlCol, shadowXxl, shadowXxlCol, shadows)
41import Fahrtwind.Style.BoxShadow (mkShadow, shadow, shadow', shadowDefault, shadowDefaultCol, shadowLg, shadowLgCol, shadowMd, shadowMdCol, shadowSm, shadowSmCol, shadowXl, shadowXlCol, shadowXxl, shadowXxlCol, shadows)
42import Fahrtwind.Style.Breakpoint (screen2xl, screenLg, screenMd, screenSm, screenXl)
42import Fahrtwind.Style.Breakpoint (screen2xl, screenLg, screenMd, screenSm, screenXl)
43−import Fahrtwind.Style.Color.Background (background, background', backgroundImage, backgroundImage', backgroundNoRepeat, backgroundPosition, backgroundRepeat, backgroundRepeatX, backgroundRepeatY, backgroundSize, backgroundSize', blurredBackground, blurredBackground', linearGradient, linearGradient', linearGradientStops, linearGradientStopsString, linearGradientString, svgBackgroundImage)
43+import Fahrtwind.Style.Color.Background (background, background', backgroundImage, backgroundImage', backgroundNoRepeat, backgroundPosition, backgroundRepeat, backgroundRepeatX, backgroundRepeatY, backgroundSize, backgroundSize', blurredBackground, blurredBackground', linearGradient, linearGradient', linearGradientStops, linearGradientStopsString, linearGradientString, linearGradientString', svgBackgroundImage)
44import Fahrtwind.Style.Color.Tailwind (TailwindColor, amber, black, blue, blueGray, coolGray, cyan, emerald, fuchsia, gray, green, indigo, lightBlue, lime, orange, pink, purple, red, rose, teal, trueGray, violet, warmGray, white, yellow)
44import Fahrtwind.Style.Color.Tailwind (TailwindColor, amber, black, blue, blueGray, coolGray, cyan, emerald, fuchsia, gray, green, indigo, lightBlue, lime, orange, pink, purple, red, rose, teal, trueGray, violet, warmGray, white, yellow)
45import Fahrtwind.Style.Color.Text (textCenter, textCol, textCol', textJustify, textLeft, textRight)
45import Fahrtwind.Style.Color.Text (textCenter, textCol, textCol', textJustify, textLeft, textRight)
46import Fahrtwind.Style.Color.Util (hue, lightness, saturation, withAlpha, withHue, withLightness, withSaturation)
46import Fahrtwind.Style.Color.Util (hue, lightness, saturation, withAlpha, withHue, withLightness, withSaturation)
@@ -48,7 +48,7 @@ import Fahrtwind.Style.Cursor (cursorAuto, cursorDefault, cursorHelp, cursorMove
48import Fahrtwind.Style.Display (block, displayNone, flex, inlineBlock, inlineFlex, inlineGrid)
48import Fahrtwind.Style.Display (block, displayNone, flex, inlineBlock, inlineFlex, inlineGrid)
49import Fahrtwind.Style.Display.Flex (alignSelfCenter, alignSelfEnd, alignSelfStart, flexCol, flexGrow, flexNoWrap, flexRow, flexShrink, flexWrap, flexWrapReverse, gap, itemsAround, itemsBetween, itemsCenter, itemsEnd, itemsEvenly, itemsStart, justifyAround, justifyBetween, justifyCenter, justifyEnd, justifyEvenly, justifySelfCenter, justifySelfEnd, justifySelfStart, justifyStart)
49import Fahrtwind.Style.Display.Flex (alignSelfCenter, alignSelfEnd, alignSelfStart, flexCol, flexGrow, flexNoWrap, flexRow, flexShrink, flexWrap, flexWrapReverse, gap, itemsAround, itemsBetween, itemsCenter, itemsEnd, itemsEvenly, itemsStart, justifyAround, justifyBetween, justifyCenter, justifyEnd, justifyEvenly, justifySelfCenter, justifySelfEnd, justifySelfStart, justifyStart)
50import Fahrtwind.Style.Display.Grid (displayGrid, templateCols, templateRows)
50import Fahrtwind.Style.Display.Grid (displayGrid, templateCols, templateRows)
51−import Fahrtwind.Style.Divide (divideCol, divideX, divideXReverse, divideY, divideYReverse)
51+import Fahrtwind.Style.Divide (divideCol, divideCol', divideX, divideXReverse, divideY, divideYReverse)
52import Fahrtwind.Style.Global (globalStyles, nest, variables)
52import Fahrtwind.Style.Global (globalStyles, nest, variables)
53import Fahrtwind.Style.Input (outlineNone, placeholder)
53import Fahrtwind.Style.Input (outlineNone, placeholder)
54import Fahrtwind.Style.Inset (bottom, bottom', left, left', right, right', top, top')
54import Fahrtwind.Style.Inset (bottom, bottom', left, left', right, right', top, top')
src/Fahrtwind/Style/Border.purs+10
@@ -1,6 +1,7 @@
1module Fahrtwind.Style.Border where
1module Fahrtwind.Style.Border where
2
2
3import Prelude
3import Prelude
4+
4import Color (Color)
5import Color (Color)
5import React.Basic.Emotion (Style, StyleProperty, borderBox, color, contentBox, css, px, rem, str)
6import React.Basic.Emotion (Style, StyleProperty, borderBox, color, contentBox, css, px, rem, str)
6
7
@@ -66,3 +67,12 @@ boxSizingBorderBox = css { boxSizing: borderBox }
66
67
67boxSizingContentBox ∷ Style
68boxSizingContentBox ∷ Style
68boxSizingContentBox = css { boxSizing: contentBox }
69boxSizingContentBox = css { boxSizing: contentBox }
70+
71+borderGradient :: { backgroundGradient :: String, borderGradient :: String } -> Style
72+borderGradient args =
73+ css
74+ { background: str $
75+ args.backgroundGradient <> " padding-box, "
76+ <> (args.borderGradient <> " border-box")
77+ , borderColor: str "transparent"
78+ }
src/Fahrtwind/Style/Color/Background.purs+4−1
@@ -63,7 +63,10 @@ backgroundSize ∷ String → Style
63backgroundSize = backgroundSize' <<< str
63backgroundSize = backgroundSize' <<< str
64
64
65linearGradient' :: Int -> Array String -> Style
65linearGradient' :: Int -> Array String -> Style
66−linearGradient' deg colours = css { background: str bg }
66+linearGradient' deg colours = css { background: str (linearGradientString' deg colours) }
67+
68+linearGradientString' :: Int -> Array String -> String
69+linearGradientString' deg colours = bg
67 where
70 where
68 bg = "linear-gradient(" <> show deg <> "deg, "
71 bg = "linear-gradient(" <> show deg <> "deg, "
69 <> intercalate "," (colours)
72 <> intercalate "," (colours)
src/Fahrtwind/Style/Text.purs+2−2
@@ -134,9 +134,9 @@ italic = css { fontStyle: str "italic" }
134textLinearGradient :: Int -> Array String -> Style
134textLinearGradient :: Int -> Array String -> Style
135textLinearGradient deg colours =
135textLinearGradient deg colours =
136 css
136 css
137+ { background: str bg
137− { backgroundClip: str "text"
138+ , backgroundClip: str "text"
138 , textFillColor: str "transparent"
139 , textFillColor: str "transparent"
139− , background: str bg
140 }
140 }
141 where
141 where
142 bg = "linear-gradient(" <> show deg <> "deg, "
142 bg = "linear-gradient(" <> show deg <> "deg, "