@astryxdesign/native 0.7.5-canary.174300f → 0.7.5-canary.1e84ea4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (26) hide show
  1. package/apple/README.md +7 -7
  2. package/apple/Sources/Astryx/Card/Card.swift +95 -19
  3. package/apple/Sources/Astryx/Heading/Heading.swift +12 -12
  4. package/apple/Sources/Astryx/Text/Text.swift +5 -5
  5. package/apple/Sources/Astryx/Text/TypeStyle.swift +36 -25
  6. package/apple/Sources/Astryx/Theme/Generated/ButterTheme.swift +44 -122
  7. package/apple/Sources/Astryx/Theme/Generated/ChocolateTheme.swift +44 -122
  8. package/apple/Sources/Astryx/Theme/Generated/DefaultTheme.swift +44 -122
  9. package/apple/Sources/Astryx/Theme/Generated/GothicTheme.swift +44 -122
  10. package/apple/Sources/Astryx/Theme/Generated/MatchaTheme.swift +44 -122
  11. package/apple/Sources/Astryx/Theme/Generated/NeutralTheme.swift +44 -122
  12. package/apple/Sources/Astryx/Theme/Generated/StoneTheme.swift +44 -122
  13. package/apple/Sources/Astryx/Theme/Generated/Tokens.swift +296 -298
  14. package/apple/Sources/Astryx/Theme/Generated/Y2kTheme.swift +44 -122
  15. package/apple/Sources/Astryx/Theme/Shadow.swift +41 -0
  16. package/apple/Sources/Astryx/Tooltip/TooltipPresenter.swift +511 -0
  17. package/apple/Sources/Astryx/Wire/AstryxNodeView.swift +75 -0
  18. package/apple/Tests/AstryxTests/CardTests.swift +131 -1
  19. package/apple/Tests/AstryxTests/EnvironmentTests.swift +2 -2
  20. package/apple/Tests/AstryxTests/HeadingTests.swift +1 -1
  21. package/apple/Tests/AstryxTests/TextTests.swift +8 -8
  22. package/apple/Tests/AstryxTests/ThemeTests.swift +2 -2
  23. package/apple/Tests/AstryxTests/TooltipPresenterTests.swift +160 -0
  24. package/apple/Tests/AstryxTests/TwoThemeTests.swift +2 -2
  25. package/package.json +3 -3
  26. package/src/theme/swiftIOSTheme.test.ts +66 -8
package/apple/README.md CHANGED
@@ -51,17 +51,15 @@ apple/
51
51
  that also imports SwiftUI, write `Astryx.Button` and `SwiftUI.Button`. A
52
52
  component's parameters use core's prop names
53
53
  and values (`variant: .primary`, `size: .lg`, `isLoading`), so code reads
54
- the same across web and native. `Text` and `Heading` take the generated
55
- `TextProps` and `HeadingProps`, as AST-093 FR5 asks; the others keep five
56
- exceptions, the interim shape FR5 exempts until they move onto the generated
54
+ the same across web and native. `Text`, `Heading`, and `Card` take the
55
+ generated `TextProps`, `HeadingProps`, and `CardProps`, as AST-093 FR5 asks;
56
+ the others keep four exceptions, the interim shape FR5 exempts until they move onto the generated
57
57
  contracts:
58
58
  - `Button` takes `action` where core has `onClick`.
59
59
  - `Button` takes `fillsWidth` where core has `width="100%"`.
60
60
  - `Button` takes `icon` as a shared icon name (`"search"`), which the
61
61
  generated `ButtonProps` does not carry yet.
62
62
  - `TextInput` takes a `Binding` where core has `value` and `onChange`.
63
- - `Card` takes `padding` as a whole spacing step, so it cannot spell
64
- core's `0.5` and `1.5` steps.
65
63
  - **`Templates/`** holds one folder per page template, named after the
66
64
  `astryx template` id. Templates are clone-only, as on the web: you copy a
67
65
  template's folder into your app and own it from then on. They are a
@@ -100,8 +98,10 @@ size.
100
98
  Components read every color, size, and font from the `astryx` environment
101
99
  value, never from a constant of their own. `astryx.tokens` holds the theme's
102
100
  tokens in the current mode as typed members (`tokens.color.textPrimary`,
103
- `tokens.space.s4`, `tokens.font.bodySize`), so a misspelled token fails to
104
- compile. Text sizes grow with Dynamic Type. The components still read some
101
+ `tokens.space.s4`, `tokens.font.body.size`), so a misspelled token fails to
102
+ compile. Font tokens come grouped: each type style (`tokens.font.body`,
103
+ `tokens.font.heading1`) holds its `size`, `weight`, and `leading`, and
104
+ `tokens.font.family`, `.size`, and `.weight` hold the scales. Text sizes grow with Dynamic Type. The components still read some
105
105
  tokens by core's name (`astryx.color("color-accent")`); moving them onto the
106
106
  typed members comes next.
107
107
 
@@ -1,33 +1,109 @@
1
1
  // Copyright (c) Meta Platforms, Inc. and affiliates.
2
2
 
3
- import SwiftUI
4
-
5
- /// A card: one independent item on the theme's card ground, with a hairline
6
- /// border and the container radius.
3
+ /// A card: one independent item on the theme's card ground. It takes core's
4
+ /// Card props (`CardProps`) and stacks its content top to bottom, as children
5
+ /// flow inside core's Card.
7
6
  public struct Card<Content: View>: View {
8
- let padding: Int
7
+ public let props: CardProps
9
8
  let content: Content
10
9
  @Environment(\.astryx) private var astryx
11
10
 
12
- /// - Parameter padding: a step on the spacing ladder, as core's `padding`.
13
- public init(padding: Int = 4, @ViewBuilder content: () -> Content) {
14
- self.padding = padding
11
+ /// - Parameters:
12
+ /// - padding: core's `padding`, a step on the spacing scale; step 4 when
13
+ /// nil.
14
+ /// - variant: core's `variant`: the card ground, or `transparent` for none.
15
+ /// Only `default` draws a border.
16
+ /// - elevation: core's `elevation`, the theme's shadow at that depth.
17
+ /// - base: core's base props.
18
+ /// - content: core's `children`.
19
+ public init(
20
+ padding: CardPadding? = nil,
21
+ variant: CardVariant? = nil,
22
+ elevation: CardElevation? = nil,
23
+ base: AstryxBaseProps = AstryxBaseProps(),
24
+ @ViewBuilder content: () -> Content
25
+ ) {
26
+ self.props = CardProps(padding: padding, variant: variant, elevation: elevation, base: base)
15
27
  self.content = content()
16
28
  }
17
29
 
18
30
  public var body: some View {
19
- let shape = RoundedRectangle(
20
- cornerRadius: astryx.size("radius-container", 12),
21
- style: .continuous
22
- )
23
- // Several child views stack in one card, top to bottom with no gap of
24
- // their own, as children flow inside core's Card.
25
- VStack(alignment: .leading, spacing: 0) { content }
26
- .padding(astryx.space(padding))
31
+ let shape = RoundedRectangle(cornerRadius: astryx.tokens.radius.container, style: .continuous)
32
+ let variant = props.variant ?? .default
33
+ // The border sits inside the padding, so the content's inset is the
34
+ // padding step, as in core.
35
+ SwiftUI.VStack(alignment: .leading, spacing: 0) { content }
36
+ .padding(padding)
27
37
  .frame(maxWidth: .infinity, alignment: .leading)
28
- .background(shape.fill(astryx.color("color-background-card")))
29
- .overlay(
30
- shape.strokeBorder(astryx.color("color-border"), lineWidth: astryx.size("border-width", 1))
38
+ .background(shape.fill(Self.ground(variant, astryx.tokens.color)))
39
+ .overlay {
40
+ if variant == .default {
41
+ shape.strokeBorder(astryx.tokens.color.border, lineWidth: astryx.tokens.size.borderWidth)
42
+ }
43
+ }
44
+ .astryxShadow(
45
+ Self.shadow(props.elevation ?? .none, astryx.tokens.shadow), in: shape,
46
+ borderWidth: variant == .default ? astryx.tokens.size.borderWidth : 0
31
47
  )
48
+ .astryxBase(props.base)
49
+ }
50
+
51
+ var padding: CGFloat {
52
+ let space = astryx.tokens.space
53
+ switch props.padding ?? .v4 {
54
+ case .v0: return space.s0
55
+ case .v0_5: return space.s0_5
56
+ case .v1: return space.s1
57
+ case .v1_5: return space.s1_5
58
+ case .v2: return space.s2
59
+ case .v3: return space.s3
60
+ case .v4: return space.s4
61
+ case .v5: return space.s5
62
+ case .v6: return space.s6
63
+ case .v8: return space.s8
64
+ case .v10: return space.s10
65
+ }
66
+ }
67
+
68
+ /// The ground core's Card draws for a variant.
69
+ static func ground(_ variant: CardVariant, _ color: ColorTokens) -> Color {
70
+ switch variant {
71
+ case .default: color.backgroundCard
72
+ case .transparent: .clear
73
+ case .muted: color.backgroundMuted
74
+ case .blue: color.backgroundBlue
75
+ case .cyan: color.backgroundCyan
76
+ case .gray: color.backgroundGray
77
+ case .green: color.backgroundGreen
78
+ case .orange: color.backgroundOrange
79
+ case .pink: color.backgroundPink
80
+ case .purple: color.backgroundPurple
81
+ case .red: color.backgroundRed
82
+ case .teal: color.backgroundTeal
83
+ case .yellow: color.backgroundYellow
84
+ }
85
+ }
86
+
87
+ /// The theme's shadow at an elevation.
88
+ static func shadow(_ elevation: CardElevation, _ shadow: ShadowTokens) -> [ShadowLayer] {
89
+ switch elevation {
90
+ case .none: []
91
+ case .low: shadow.low
92
+ case .med: shadow.med
93
+ case .high: shadow.high
94
+ }
95
+ }
96
+ }
97
+
98
+ extension Card where Content == AstryxNodeList {
99
+ /// A card from core's props, with its children as the wire tree a logic
100
+ /// core sends; `send` carries the children's callbacks back to the core.
101
+ public init(
102
+ _ props: CardProps,
103
+ children: [AstryxNode],
104
+ send: @escaping @Sendable (AstryxAction) -> Void
105
+ ) {
106
+ self.props = props
107
+ self.content = AstryxNodeList(nodes: children, send: send)
32
108
  }
33
109
  }
@@ -68,7 +68,7 @@ public struct Heading: View {
68
68
  func styled(_ text: SwiftUI.Text) -> SwiftUI.Text {
69
69
  var style = typeStyle
70
70
  if let weight = props.weight {
71
- style.weight = astryx.tokens.font.weight(named: weight.rawValue)
71
+ style.weight = astryx.tokens.font.weight.value(named: weight.rawValue)
72
72
  }
73
73
  var text = text.font(astryx.font(style))
74
74
  if let color = astryx.tokens.color.text(named: (props.color ?? .primary).rawValue) {
@@ -82,22 +82,22 @@ public struct Heading: View {
82
82
  /// theme's heading family.
83
83
  var typeStyle: TypeStyle {
84
84
  let font = astryx.tokens.font
85
- let (size, weight): (CGFloat, CGFloat) =
85
+ let style: TypeStyleTokens =
86
86
  switch props.type {
87
- case .display1: (font.display1Size, font.display1Weight)
88
- case .display2: (font.display2Size, font.display2Weight)
89
- case .display3: (font.display3Size, font.display3Weight)
87
+ case .display1: font.display1
88
+ case .display2: font.display2
89
+ case .display3: font.display3
90
90
  case nil:
91
91
  switch props.level {
92
- case .v1: (font.heading1Size, font.heading1Weight)
93
- case .v2: (font.heading2Size, font.heading2Weight)
94
- case .v3: (font.heading3Size, font.heading3Weight)
95
- case .v4: (font.heading4Size, font.heading4Weight)
96
- case .v5: (font.heading5Size, font.heading5Weight)
97
- case .v6: (font.heading6Size, font.heading6Weight)
92
+ case .v1: font.heading1
93
+ case .v2: font.heading2
94
+ case .v3: font.heading3
95
+ case .v4: font.heading4
96
+ case .v5: font.heading5
97
+ case .v6: font.heading6
98
98
  }
99
99
  }
100
- return TypeStyle(size: size, weight: weight, families: font.familyHeading)
100
+ return TypeStyle(style, families: font.family.heading)
101
101
  }
102
102
 
103
103
  /// The traits assistive technology gets: a header.
@@ -71,17 +71,17 @@ public struct Text: View {
71
71
  let type = props.type ?? .body
72
72
  if let style = font.style(type) {
73
73
  var style = style
74
- if let size = props.size { style.size = font.size(size) }
75
- if let weight = props.weight { style.weight = font.weight(named: weight.rawValue) }
74
+ if let size = props.size { style.size = font.size.value(for: size) }
75
+ if let weight = props.weight { style.weight = font.weight.value(named: weight.rawValue) }
76
76
  text = text.font(astryx.font(style))
77
77
  } else if let size = props.size {
78
78
  // `inherit` with a size: SwiftUI cannot change only the size of an
79
79
  // inherited font, so it draws the body family at normal weight (or the
80
80
  // given weight) at that size, a documented gap.
81
- let weight = font.weight(named: props.weight?.rawValue ?? "normal")
82
- text = text.font(astryx.font(TypeStyle(size: font.size(size), weight: weight, families: font.familyBody)))
81
+ let weight = font.weight.value(named: props.weight?.rawValue ?? "normal")
82
+ text = text.font(astryx.font(TypeStyle(size: font.size.value(for: size), weight: weight, families: font.family.body)))
83
83
  } else if let weight = props.weight {
84
- text = text.fontWeight(astryx.fontWeight(font.weight(named: weight.rawValue)))
84
+ text = text.fontWeight(astryx.fontWeight(font.weight.value(named: weight.rawValue)))
85
85
  }
86
86
  if let color = astryx.tokens.color.text(named: (props.color ?? Self.defaultColor(type)).rawValue) {
87
87
  text = text.foregroundStyle(color)
@@ -8,48 +8,59 @@ struct TypeStyle: Equatable {
8
8
  var families: [String]
9
9
  }
10
10
 
11
+ extension TypeStyle {
12
+ /// A theme type style drawn in a family stack.
13
+ init(_ tokens: TypeStyleTokens, families: [String]) {
14
+ self.init(size: tokens.size, weight: tokens.weight, families: families)
15
+ }
16
+ }
17
+
11
18
  extension FontTokens {
12
19
  /// The style core's Text draws for a type, or nil for `inherit`. Display
13
20
  /// types draw in the heading family, as core's type scale sets them.
14
21
  func style(_ type: TextType) -> TypeStyle? {
15
22
  switch type {
16
- case .body: TypeStyle(size: bodySize, weight: bodyWeight, families: familyBody)
17
- case .large: TypeStyle(size: largeSize, weight: largeWeight, families: familyBody)
18
- case .label: TypeStyle(size: labelSize, weight: labelWeight, families: familyBody)
19
- case .supporting: TypeStyle(size: supportingSize, weight: supportingWeight, families: familyBody)
20
- case .code: TypeStyle(size: codeSize, weight: codeWeight, families: familyCode)
21
- case .display1: TypeStyle(size: display1Size, weight: display1Weight, families: familyHeading)
22
- case .display2: TypeStyle(size: display2Size, weight: display2Weight, families: familyHeading)
23
- case .display3: TypeStyle(size: display3Size, weight: display3Weight, families: familyHeading)
23
+ case .body: TypeStyle(body, families: family.body)
24
+ case .large: TypeStyle(large, families: family.body)
25
+ case .label: TypeStyle(label, families: family.body)
26
+ case .supporting: TypeStyle(supporting, families: family.body)
27
+ case .code: TypeStyle(code, families: family.code)
28
+ case .display1: TypeStyle(display1, families: family.heading)
29
+ case .display2: TypeStyle(display2, families: family.heading)
30
+ case .display3: TypeStyle(display3, families: family.heading)
24
31
  case .inherit: nil
25
32
  }
26
33
  }
34
+ }
27
35
 
36
+ extension FontSizeTokens {
28
37
  /// The font size core's Text draws for an explicit `size`. Core spells the
29
38
  /// extra-small size `xsm`; its token is `font-size-xs`.
30
- func size(_ size: TextSize) -> CGFloat {
39
+ func value(for size: TextSize) -> CGFloat {
31
40
  switch size {
32
- case .v4xs: size4xs
33
- case .v3xs: size3xs
34
- case .v2xs: size2xs
35
- case .xsm: sizeXs
36
- case .sm: sizeSm
37
- case .base: sizeBase
38
- case .lg: sizeLg
39
- case .xl: sizeXl
40
- case .v2xl: size2xl
41
- case .v3xl: size3xl
42
- case .v4xl: size4xl
41
+ case .v4xs: s4xs
42
+ case .v3xs: s3xs
43
+ case .v2xs: s2xs
44
+ case .xsm: xs
45
+ case .sm: sm
46
+ case .base: base
47
+ case .lg: lg
48
+ case .xl: xl
49
+ case .v2xl: s2xl
50
+ case .v3xl: s3xl
51
+ case .v4xl: s4xl
43
52
  }
44
53
  }
54
+ }
45
55
 
56
+ extension FontWeightTokens {
46
57
  /// The numeric weight behind one of core's weight names.
47
- func weight(named name: String) -> CGFloat {
58
+ func value(named name: String) -> CGFloat {
48
59
  switch name {
49
- case "medium": weightMedium
50
- case "semibold": weightSemibold
51
- case "bold": weightBold
52
- default: weightNormal
60
+ case "medium": medium
61
+ case "semibold": semibold
62
+ case "bold": bold
63
+ default: normal
53
64
  }
54
65
  }
55
66
  }
@@ -197,67 +197,28 @@ extension Theme {
197
197
  elementSm: 32
198
198
  ),
199
199
  font: FontTokens(
200
- bodyLeading: 1.4286,
201
- bodySize: 14,
202
- bodyWeight: 400,
203
- codeLeading: 1.4286,
204
- codeSize: 14,
205
- codeWeight: 400,
206
- display1Leading: 1.283,
207
- display1Size: 53,
208
- display1Weight: 400,
209
- display2Leading: 1.2093,
210
- display2Size: 43,
211
- display2Weight: 400,
212
- display3Leading: 1.2941,
213
- display3Size: 34,
214
- display3Weight: 400,
215
- familyBody: ["Outfit", "-apple-system", "BlinkMacSystemFont", "Segoe UI", "Roboto", "Helvetica", "Arial", "sans-serif"],
216
- familyCode: ["JetBrains Mono", "SF Mono", "Monaco", "Consolas", "monospace"],
217
- familyHeading: ["Outfit", "-apple-system", "BlinkMacSystemFont", "Segoe UI", "Roboto", "Helvetica", "Arial", "sans-serif"],
218
- heading1Leading: 1.3333,
219
- heading1Size: 27,
220
- heading1Weight: 600,
221
- heading2Leading: 1.4545,
222
- heading2Size: 22,
223
- heading2Weight: 600,
224
- heading3Leading: 1.5556,
225
- heading3Size: 18,
226
- heading3Weight: 700,
227
- heading4Leading: 1.4286,
228
- heading4Size: 14,
229
- heading4Weight: 700,
230
- heading5Leading: 1.4545,
231
- heading5Size: 11,
232
- heading5Weight: 600,
233
- heading6Leading: 1.7778,
234
- heading6Size: 9,
235
- heading6Weight: 600,
236
- labelLeading: 1.4286,
237
- labelSize: 14,
238
- labelWeight: 500,
239
- largeLeading: 1.5556,
240
- largeSize: 18,
241
- largeWeight: 600,
242
- size2xl: 27,
243
- size2xs: 7,
244
- size3xl: 34,
245
- size3xs: 6,
246
- size4xl: 43,
247
- size4xs: 5,
248
- size5xl: 53,
249
- sizeBase: 14,
250
- sizeLg: 18,
251
- sizeSm: 11,
252
- sizeXl: 22,
253
- sizeXs: 9,
254
- supportingLeading: 1.4545,
255
- supportingSize: 12,
256
- supportingWeight: 400,
257
- weightBold: 700,
258
- weightMedium: 500,
259
- weightNormal: 400,
260
- weightSemibold: 600
200
+ body: TypeStyleTokens(size: 14, weight: 400, leading: 1.4286),
201
+ code: TypeStyleTokens(size: 14, weight: 400, leading: 1.4286),
202
+ display1: TypeStyleTokens(size: 53, weight: 400, leading: 1.283),
203
+ display2: TypeStyleTokens(size: 43, weight: 400, leading: 1.2093),
204
+ display3: TypeStyleTokens(size: 34, weight: 400, leading: 1.2941),
205
+ family: FontFamilyTokens(body: ["Outfit", "-apple-system", "BlinkMacSystemFont", "Segoe UI", "Roboto", "Helvetica", "Arial", "sans-serif"], code: ["JetBrains Mono", "SF Mono", "Monaco", "Consolas", "monospace"], heading: ["Outfit", "-apple-system", "BlinkMacSystemFont", "Segoe UI", "Roboto", "Helvetica", "Arial", "sans-serif"]),
206
+ heading1: TypeStyleTokens(size: 27, weight: 600, leading: 1.3333),
207
+ heading2: TypeStyleTokens(size: 22, weight: 600, leading: 1.4545),
208
+ heading3: TypeStyleTokens(size: 18, weight: 700, leading: 1.5556),
209
+ heading4: TypeStyleTokens(size: 14, weight: 700, leading: 1.4286),
210
+ heading5: TypeStyleTokens(size: 11, weight: 600, leading: 1.4545),
211
+ heading6: TypeStyleTokens(size: 9, weight: 600, leading: 1.7778),
212
+ label: TypeStyleTokens(size: 14, weight: 500, leading: 1.4286),
213
+ large: TypeStyleTokens(size: 18, weight: 600, leading: 1.5556),
214
+ size: FontSizeTokens(base: 14, lg: 18, s2xl: 27, s2xs: 7, s3xl: 34, s3xs: 6, s4xl: 43, s4xs: 5, s5xl: 53, sm: 11, xl: 22, xs: 9),
215
+ supporting: TypeStyleTokens(size: 12, weight: 400, leading: 1.4545),
216
+ weight: FontWeightTokens(bold: 700, medium: 500, normal: 400, semibold: 600)
217
+ ),
218
+ shadow: ShadowTokens(
219
+ high: [ShadowLayer(x: 0, y: 4, blur: 6, color: Color(astryxRGBA: 0x1D1C111A)), ShadowLayer(x: 0, y: 12, blur: 24, color: Color(astryxRGBA: 0x1D1C1126))],
220
+ low: [ShadowLayer(x: 0, y: 2, blur: 4, color: Color(astryxRGBA: 0x1D1C110D)), ShadowLayer(x: 0, y: 4, blur: 8, color: Color(astryxRGBA: 0x1D1C111A))],
221
+ med: [ShadowLayer(x: 0, y: 2, blur: 4, color: Color(astryxRGBA: 0x1D1C110D)), ShadowLayer(x: 0, y: 4, blur: 12, color: Color(astryxRGBA: 0x1D1C111A))]
261
222
  )
262
223
  ),
263
224
  dark: Tokens(
@@ -450,67 +411,28 @@ extension Theme {
450
411
  elementSm: 32
451
412
  ),
452
413
  font: FontTokens(
453
- bodyLeading: 1.4286,
454
- bodySize: 14,
455
- bodyWeight: 400,
456
- codeLeading: 1.4286,
457
- codeSize: 14,
458
- codeWeight: 400,
459
- display1Leading: 1.283,
460
- display1Size: 53,
461
- display1Weight: 400,
462
- display2Leading: 1.2093,
463
- display2Size: 43,
464
- display2Weight: 400,
465
- display3Leading: 1.2941,
466
- display3Size: 34,
467
- display3Weight: 400,
468
- familyBody: ["Outfit", "-apple-system", "BlinkMacSystemFont", "Segoe UI", "Roboto", "Helvetica", "Arial", "sans-serif"],
469
- familyCode: ["JetBrains Mono", "SF Mono", "Monaco", "Consolas", "monospace"],
470
- familyHeading: ["Outfit", "-apple-system", "BlinkMacSystemFont", "Segoe UI", "Roboto", "Helvetica", "Arial", "sans-serif"],
471
- heading1Leading: 1.3333,
472
- heading1Size: 27,
473
- heading1Weight: 600,
474
- heading2Leading: 1.4545,
475
- heading2Size: 22,
476
- heading2Weight: 600,
477
- heading3Leading: 1.5556,
478
- heading3Size: 18,
479
- heading3Weight: 700,
480
- heading4Leading: 1.4286,
481
- heading4Size: 14,
482
- heading4Weight: 700,
483
- heading5Leading: 1.4545,
484
- heading5Size: 11,
485
- heading5Weight: 600,
486
- heading6Leading: 1.7778,
487
- heading6Size: 9,
488
- heading6Weight: 600,
489
- labelLeading: 1.4286,
490
- labelSize: 14,
491
- labelWeight: 500,
492
- largeLeading: 1.5556,
493
- largeSize: 18,
494
- largeWeight: 600,
495
- size2xl: 27,
496
- size2xs: 7,
497
- size3xl: 34,
498
- size3xs: 6,
499
- size4xl: 43,
500
- size4xs: 5,
501
- size5xl: 53,
502
- sizeBase: 14,
503
- sizeLg: 18,
504
- sizeSm: 11,
505
- sizeXl: 22,
506
- sizeXs: 9,
507
- supportingLeading: 1.4545,
508
- supportingSize: 12,
509
- supportingWeight: 400,
510
- weightBold: 700,
511
- weightMedium: 500,
512
- weightNormal: 400,
513
- weightSemibold: 600
414
+ body: TypeStyleTokens(size: 14, weight: 400, leading: 1.4286),
415
+ code: TypeStyleTokens(size: 14, weight: 400, leading: 1.4286),
416
+ display1: TypeStyleTokens(size: 53, weight: 400, leading: 1.283),
417
+ display2: TypeStyleTokens(size: 43, weight: 400, leading: 1.2093),
418
+ display3: TypeStyleTokens(size: 34, weight: 400, leading: 1.2941),
419
+ family: FontFamilyTokens(body: ["Outfit", "-apple-system", "BlinkMacSystemFont", "Segoe UI", "Roboto", "Helvetica", "Arial", "sans-serif"], code: ["JetBrains Mono", "SF Mono", "Monaco", "Consolas", "monospace"], heading: ["Outfit", "-apple-system", "BlinkMacSystemFont", "Segoe UI", "Roboto", "Helvetica", "Arial", "sans-serif"]),
420
+ heading1: TypeStyleTokens(size: 27, weight: 600, leading: 1.3333),
421
+ heading2: TypeStyleTokens(size: 22, weight: 600, leading: 1.4545),
422
+ heading3: TypeStyleTokens(size: 18, weight: 700, leading: 1.5556),
423
+ heading4: TypeStyleTokens(size: 14, weight: 700, leading: 1.4286),
424
+ heading5: TypeStyleTokens(size: 11, weight: 600, leading: 1.4545),
425
+ heading6: TypeStyleTokens(size: 9, weight: 600, leading: 1.7778),
426
+ label: TypeStyleTokens(size: 14, weight: 500, leading: 1.4286),
427
+ large: TypeStyleTokens(size: 18, weight: 600, leading: 1.5556),
428
+ size: FontSizeTokens(base: 14, lg: 18, s2xl: 27, s2xs: 7, s3xl: 34, s3xs: 6, s4xl: 43, s4xs: 5, s5xl: 53, sm: 11, xl: 22, xs: 9),
429
+ supporting: TypeStyleTokens(size: 12, weight: 400, leading: 1.4545),
430
+ weight: FontWeightTokens(bold: 700, medium: 500, normal: 400, semibold: 600)
431
+ ),
432
+ shadow: ShadowTokens(
433
+ high: [ShadowLayer(x: 0, y: 4, blur: 6, color: Color(astryxRGBA: 0x1D1C111A)), ShadowLayer(x: 0, y: 12, blur: 24, color: Color(astryxRGBA: 0x1D1C1126))],
434
+ low: [ShadowLayer(x: 0, y: 2, blur: 4, color: Color(astryxRGBA: 0x1D1C110D)), ShadowLayer(x: 0, y: 4, blur: 8, color: Color(astryxRGBA: 0x1D1C111A))],
435
+ med: [ShadowLayer(x: 0, y: 2, blur: 4, color: Color(astryxRGBA: 0x1D1C110D)), ShadowLayer(x: 0, y: 4, blur: 12, color: Color(astryxRGBA: 0x1D1C111A))]
514
436
  )
515
437
  )
516
438
  )