ply-css 1.7.1 → 1.8.0

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.
package/llms-full.txt CHANGED
@@ -297,6 +297,15 @@ Key variables for mapping:
297
297
 
298
298
  This ensures third-party components follow ply's theme automatically, including dark mode and custom themes.
299
299
 
300
+ ### Token Scales
301
+
302
+ ply exposes three scales so size and shape are themeable from a few variables:
303
+
304
+ - **Border radius** — `--ply-radius-none/xs/sm/md/lg/xl/full` scale, consumed by semantic aliases `--ply-border-radius` (`= radius-sm`), `--ply-btn-border-radius` (`= radius-full`), `--ply-label-radius` (`= radius-sm`), `--ply-badge-radius` (`= radius-full`), `--ply-input-radius` (`= radius-sm`). Override the scale once or retarget one alias.
305
+ - **Control sizing** — `--ply-control-{font,py,px,lh}` (+ `-lg`/`-sm`/`-xs`) are shared by inputs, buttons, selects, and textareas, so a given size renders the same height across every control. Height is emergent (`padding-y × 2 + line-height`), never fixed.
306
+ - **Spacing** — `--ply-space-xs/sm/md`, `--ply-space` (the 16px default unit), `--ply-space-lg/xl/xxl`.
307
+ - **Inverse & black** — `--ply-bg-inverse` and `--ply-layer-inverse-0/1` reference the text-color variables (flip opposite the body automatically); `--ply-color-black` is `#000` in every mode.
308
+
300
309
  ---
301
310
 
302
311
  ## Navigation — Semantic and Responsive
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ply-css",
3
- "version": "1.7.1",
3
+ "version": "1.8.0",
4
4
  "description": "ply — A ratio-based, AI-ready CSS framework with dark mode, accessibility, and a small footprint",
5
5
  "main": "dist/css/ply.css",
6
6
  "style": "dist/css/ply.min.css",
package/ply-classes.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "1.7.1",
2
+ "version": "1.8.0",
3
3
  "framework": "ply",
4
4
  "totalClasses": 457,
5
5
  "uniqueClasses": 457,
@@ -63,7 +63,7 @@
63
63
  },
64
64
  "themeTemplate": {
65
65
  "description": "Copy-paste starting point for custom themes. Replace placeholder values with your design colors. Every ply component respects these variables.",
66
- "css": "[data-theme=\"my-theme\"] {\n /* Background */\n --ply-bg-body: #___;\n --ply-bg-surface: #___;\n --ply-bg-surface-alt: #___;\n --ply-bg-muted: #___;\n\n /* Text */\n --ply-color-body: #___;\n --ply-color-headings: #___;\n --ply-color-secondary: #___;\n --ply-color-muted: #___;\n --ply-color-placeholder: #___;\n --ply-color-text-inverse: #___;\n\n /* Borders */\n --ply-border-color: #___;\n --ply-border-strong: #___;\n --ply-border-radius: 0.25rem;\n\n /* Interactive */\n --ply-color-accent: #___;\n --ply-color-focus: #___;\n --ply-color-link-hover: #___;\n\n /* Buttons */\n --ply-btn-default-bg: #___;\n --ply-btn-default-color: #___;\n --ply-btn-default-bg-hover: #___;\n --ply-btn-default-bg-active: #___;\n --ply-btn-secondary-bg: #___;\n --ply-btn-secondary-color: #___;\n --ply-btn-secondary-bg-hover: #___;\n --ply-btn-secondary-bg-active: #___;\n --ply-btn-border-radius: 2rem;\n --ply-btn-font-size: 1em;\n --ply-btn-gap: 0.5em;\n\n /* Forms */\n --ply-color-input-bg: #___;\n --ply-color-input-border: #___;\n --ply-color-error: #___;\n --ply-color-success: #___;\n\n /* Navigation */\n --ply-nav-bg: #___;\n --ply-nav-color: #___;\n --ply-nav-border: #___;\n --ply-nav-hover: #___;\n\n /* Code */\n --ply-color-code-bg: #___;\n --ply-color-code-border: #___;\n\n /* Tables */\n --ply-color-table-border: #___;\n --ply-color-table-striped: #___;\n\n /* Elevation */\n --ply-layer-0: #___;\n --ply-layer-1: #___;\n --ply-layer-2: #___;\n --ply-layer-3: #___;\n --ply-shadow-1: rgba(0, 0, 0, 0.08);\n --ply-shadow-2: rgba(0, 0, 0, 0.1);\n --ply-shadow-3: rgba(0, 0, 0, 0.12);\n\n /* Typography (optional) */\n --ply-font-body: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;\n --ply-font-heading: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;\n --ply-font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;\n}"
66
+ "css": "[data-theme=\"my-theme\"] {\n /* Background */\n --ply-bg-body: #___;\n --ply-bg-surface: #___;\n --ply-bg-surface-alt: #___;\n --ply-bg-muted: #___;\n\n /* Text */\n --ply-color-body: #___;\n --ply-color-headings: #___;\n --ply-color-secondary: #___;\n --ply-color-muted: #___;\n --ply-color-placeholder: #___;\n --ply-color-text-inverse: #___;\n\n /* Borders */\n --ply-border-color: #___;\n --ply-border-strong: #___;\n --ply-border-radius: 0.25rem;\n\n /* Interactive */\n --ply-color-accent: #___;\n --ply-color-focus: #___;\n --ply-color-link-hover: #___;\n\n /* Buttons */\n --ply-btn-default-bg: #___;\n --ply-btn-default-color: #___;\n --ply-btn-default-bg-hover: #___;\n --ply-btn-default-bg-active: #___;\n --ply-btn-secondary-bg: #___;\n --ply-btn-secondary-color: #___;\n --ply-btn-secondary-bg-hover: #___;\n --ply-btn-secondary-bg-active: #___;\n --ply-btn-border-radius: 2rem;\n --ply-btn-font-size: 1em;\n --ply-btn-gap: 0.5em;\n\n /* Forms */\n --ply-color-input-bg: #___;\n --ply-color-input-border: #___;\n --ply-color-error: #___;\n --ply-color-success: #___;\n\n /* Navigation */\n --ply-nav-bg: #___;\n --ply-nav-color: #___;\n --ply-nav-border: #___;\n --ply-nav-hover: #___;\n\n /* Code */\n --ply-color-code-bg: #___;\n --ply-color-code-border: #___;\n\n /* Tables */\n --ply-color-table-border: #___;\n --ply-color-table-striped: #___;\n\n /* Elevation */\n --ply-layer-0: #___;\n --ply-layer-1: #___;\n --ply-layer-2: #___;\n --ply-layer-3: #___;\n --ply-shadow-1: rgba(0, 0, 0, 0.08);\n --ply-shadow-2: rgba(0, 0, 0, 0.1);\n --ply-shadow-3: rgba(0, 0, 0, 0.12);\n\n /* Typography (optional) */\n --ply-font-body: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;\n --ply-font-heading: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;\n --ply-font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;\n\n /* Border radius scale */\n --ply-radius-sm: 0.25rem;\n --ply-radius-md: 0.5rem;\n --ply-radius-lg: 0.75rem;\n --ply-radius-full: 9999px;\n --ply-border-radius: var(--ply-radius-sm);\n --ply-btn-border-radius: var(--ply-radius-full);\n --ply-label-radius: var(--ply-radius-sm);\n --ply-badge-radius: var(--ply-radius-full);\n\n /* Control sizing (inputs, buttons, selects, textareas share these) */\n --ply-control-font: 1rem;\n --ply-control-py: 0.625rem;\n --ply-control-px: 1.5rem;\n --ply-control-lh: 1.5rem;\n\n /* Spacing */\n --ply-space: 1rem;\n\n /* Inverse / black */\n --ply-bg-inverse: var(--ply-color-body);\n --ply-color-black: #000000;\n}"
67
67
  },
68
68
  "classes": {
69
69
  "units-container": {
@@ -2450,7 +2450,8 @@
2450
2450
  "--ply-bg-surface": "Card/panel background. Light: #ffffff, Dark: #262626",
2451
2451
  "--ply-bg-surface-alt": "Alternate surface. Light: #f4f4f4, Dark: #333333",
2452
2452
  "--ply-bg-muted": "Muted/hover background. Light: #e0e0e0, Dark: #393939",
2453
- "--ply-bg-glass": "Frosted glass overlay. backdrop-filter: blur(8px). Light: rgba(255,255,255,0.15), Dark: rgba(38,38,38,0.25)"
2453
+ "--ply-bg-glass": "Frosted glass overlay. backdrop-filter: blur(8px). Light: rgba(255,255,255,0.15), Dark: rgba(38,38,38,0.25)",
2454
+ "--ply-bg-inverse": "Surface opposite the body (= --ply-color-body). Light: #161616, Dark: #f4f4f4"
2454
2455
  },
2455
2456
  "text": {
2456
2457
  "--ply-color-body": "Primary text color. Light: #161616, Dark: #f4f4f4",
@@ -2458,13 +2459,28 @@
2458
2459
  "--ply-color-secondary": "Secondary text. Light: #525252, Dark: #c6c6c6",
2459
2460
  "--ply-color-muted": "Muted/tertiary text (supplementary content). Light: #767676, Dark: #8d8d8d",
2460
2461
  "--ply-color-placeholder": "Input placeholder text. Light: #a8a8a8, Dark: #6f6f6f",
2461
- "--ply-color-text-inverse": "Inverse text (for colored backgrounds). Light: #fff, Dark: #fff"
2462
+ "--ply-color-text-inverse": "Inverse text (for colored backgrounds). Light: #fff, Dark: #fff",
2463
+ "--ply-color-black": "Absolute black, mode-independent. #000000"
2462
2464
  },
2463
2465
  "borders": {
2464
2466
  "--ply-border-color": "Standard border. Light: #e0e0e0, Dark: #525252",
2465
2467
  "--ply-border-strong": "Emphasized border. Light: #8d8d8d, Dark: #6f6f6f",
2466
2468
  "--ply-border-radius": "Global border-radius for inputs, cards, dialogs, details, notifications, and other components. Default: 0.25rem. Override to change the overall shape language (e.g., 0 for sharp, 0.5rem for softer)."
2467
2469
  },
2470
+ "radius": {
2471
+ "--ply-radius-none": "Radius scale: square. Default: 0",
2472
+ "--ply-radius-xs": "Radius scale. Default: 0.125rem (2px)",
2473
+ "--ply-radius-sm": "Radius scale. Default: 0.25rem (4px)",
2474
+ "--ply-radius-md": "Radius scale. Default: 0.5rem (8px)",
2475
+ "--ply-radius-lg": "Radius scale. Default: 0.75rem (12px)",
2476
+ "--ply-radius-xl": "Radius scale. Default: 1rem (16px)",
2477
+ "--ply-radius-full": "Radius scale: pill/circle. Default: 9999px",
2478
+ "--ply-border-radius": "Default element radius alias. Default: var(--ply-radius-sm)",
2479
+ "--ply-btn-border-radius": "Button radius alias. Default: var(--ply-radius-full)",
2480
+ "--ply-label-radius": "Label radius alias. Default: var(--ply-radius-sm)",
2481
+ "--ply-badge-radius": "Badge radius alias. Default: var(--ply-radius-full)",
2482
+ "--ply-input-radius": "Input radius alias. Default: var(--ply-radius-sm)"
2483
+ },
2468
2484
  "interactive": {
2469
2485
  "--ply-color-accent": "Brand accent color for icons, badges, and section accents. Independent of button color and focus rings. Light: #0353e9, Dark: #4589ff. Override in custom themes without affecting buttons.",
2470
2486
  "--ply-color-link": "Link color. Light: #0f62fe, Dark: #78a9ff",
@@ -2479,6 +2495,24 @@
2479
2495
  "--ply-color-error": "Error state color for borders and text. Defaults to var(--ply-red-1). Used by .input-error, .error, .required, and stepper error states.",
2480
2496
  "--ply-color-success": "Success state color for borders and text. Defaults to var(--ply-green-1). Used by .input-success, .success, and stepper completed states."
2481
2497
  },
2498
+ "controlSizing": {
2499
+ "--ply-control-font-lg": "Control font-size (Large). Default: 1.125rem",
2500
+ "--ply-control-font": "Control font-size (Default). Default: 1rem",
2501
+ "--ply-control-font-sm": "Control font-size (Small). Default: 0.875rem",
2502
+ "--ply-control-font-xs": "Control font-size (XSmall). Default: 0.75rem",
2503
+ "--ply-control-py-lg": "Control vertical padding (Large). Default: 0.875rem",
2504
+ "--ply-control-py": "Control vertical padding (Default). Default: 0.625rem",
2505
+ "--ply-control-py-sm": "Control vertical padding (Small). Default: 0.375rem",
2506
+ "--ply-control-py-xs": "Control vertical padding (XSmall). Default: 0.25rem",
2507
+ "--ply-control-px-lg": "Control horizontal padding (Large). Default: 2rem",
2508
+ "--ply-control-px": "Control horizontal padding (Default). Default: 1.5rem",
2509
+ "--ply-control-px-sm": "Control horizontal padding (Small). Default: 1rem",
2510
+ "--ply-control-px-xs": "Control horizontal padding (XSmall). Default: 0.75rem",
2511
+ "--ply-control-lh-lg": "Control line-height (Large). Default: 1.75rem",
2512
+ "--ply-control-lh": "Control line-height (Default). Default: 1.5rem",
2513
+ "--ply-control-lh-sm": "Control line-height (Small). Default: 1.25rem",
2514
+ "--ply-control-lh-xs": "Control line-height (XSmall). Default: 1rem"
2515
+ },
2482
2516
  "code": {
2483
2517
  "--ply-color-code-bg": "Inline code background. Light: #f4f4f4, Dark: #333333",
2484
2518
  "--ply-color-code-border": "Inline code border. Light: #e0e0e0, Dark: #525252"
@@ -2510,7 +2544,9 @@
2510
2544
  "--ply-layer-3": "Highest layer. Light: #c6c6c6, Dark: #525252",
2511
2545
  "--ply-shadow-1": "Subtle shadow. Light: rgba(0,0,0,0.08), Dark: rgba(0,0,0,0.2)",
2512
2546
  "--ply-shadow-2": "Medium shadow. Light: rgba(0,0,0,0.1), Dark: rgba(0,0,0,0.3)",
2513
- "--ply-shadow-3": "Heavy shadow. Light: rgba(0,0,0,0.12), Dark: rgba(0,0,0,0.4)"
2547
+ "--ply-shadow-3": "Heavy shadow. Light: rgba(0,0,0,0.12), Dark: rgba(0,0,0,0.4)",
2548
+ "--ply-layer-inverse-0": "Base inverse layer (= --ply-color-body). Light: #161616, Dark: #f4f4f4",
2549
+ "--ply-layer-inverse-1": "Raised inverse layer (= --ply-color-secondary). Light: #525252, Dark: #c6c6c6"
2514
2550
  },
2515
2551
  "brand": {
2516
2552
  "--ply-bg-blue": "Blue button/badge bg. #0f62fe (same both themes)",
@@ -2542,6 +2578,7 @@
2542
2578
  "--ply-space-xs": "Extra-small spacing unit. Default: 0.25rem",
2543
2579
  "--ply-space-sm": "Small spacing unit. Default: 0.5rem",
2544
2580
  "--ply-space-md": "Medium spacing unit. Default: 0.75rem",
2581
+ "--ply-space": "Default spacing unit. Default: 1rem (16px)",
2545
2582
  "--ply-space-lg": "Large spacing unit. Default: 1.5rem",
2546
2583
  "--ply-space-xl": "Extra-large spacing unit. Default: 2rem",
2547
2584
  "--ply-space-xxl": "Extra extra large spacing unit. Default: 3rem"
@@ -2568,7 +2605,7 @@
2568
2605
  "--ply-cyan-surface": "Theme-aware cyan pastel background. Light: cyan pastel, Dark: dark muted cyan. For cards, badges, alerts.",
2569
2606
  "--ply-cyan-border": "Theme-aware cyan border. Light: light cyan tint, Dark: medium-dark cyan. For colored card borders."
2570
2607
  },
2571
- "totalCustomProperties": 92
2608
+ "totalCustomProperties": 131
2572
2609
  },
2573
2610
  "semanticElements": {
2574
2611
  "dialog": {
@@ -19,10 +19,10 @@ button.btn {
19
19
  gap: var(--ply-btn-gap, 0.5em);
20
20
 
21
21
  font-family: var(--ply-font-body, #{variables.$font-family-controls});
22
- font-size: var(--ply-btn-font-size, 1em);
22
+ font-size: var(--ply-btn-font-size, var(--ply-control-font));
23
23
  font-weight: 400;
24
24
 
25
- line-height: variables.$base-line;
25
+ line-height: var(--ply-control-lh);
26
26
 
27
27
  text-decoration: none;
28
28
  color: var(--ply-btn-secondary-color, var(--ply-color-text-inverse, #fff));
@@ -36,7 +36,7 @@ button.btn {
36
36
  box-shadow: none;
37
37
  cursor: pointer;
38
38
  background: var(--ply-btn-secondary-bg, #393939);
39
- padding: variables.$padding-btn;
39
+ padding: var(--ply-control-py) var(--ply-control-px);
40
40
 
41
41
  &:hover,
42
42
  &:active,
@@ -77,8 +77,9 @@ input[type="submit"].btn-lg,
77
77
  input[type="button"].btn-lg,
78
78
  input[type="reset"].btn-lg,
79
79
  button.btn-lg {
80
- font-size: variables.$font-size-big;
81
- padding: 0.875rem 2rem;
80
+ font-size: var(--ply-control-font-lg);
81
+ line-height: var(--ply-control-lh-lg);
82
+ padding: var(--ply-control-py-lg) var(--ply-control-px-lg);
82
83
  }
83
84
 
84
85
  .btn-sm,
@@ -86,8 +87,9 @@ input[type="submit"].btn-sm,
86
87
  input[type="button"].btn-sm,
87
88
  input[type="reset"].btn-sm,
88
89
  button.btn-sm {
89
- font-size: variables.$font-size-small;
90
- padding: 0.375rem 1rem;
90
+ font-size: var(--ply-control-font-sm);
91
+ line-height: var(--ply-control-lh-sm);
92
+ padding: var(--ply-control-py-sm) var(--ply-control-px-sm);
91
93
  }
92
94
 
93
95
  .btn-xs,
@@ -95,8 +97,9 @@ input[type="submit"].btn-xs,
95
97
  input[type="button"].btn-xs,
96
98
  input[type="reset"].btn-xs,
97
99
  button.btn-xs {
98
- font-size: variables.$font-size-smaller;
99
- padding: 0.25rem 0.75rem;
100
+ font-size: var(--ply-control-font-xs);
101
+ line-height: var(--ply-control-lh-xs);
102
+ padding: var(--ply-control-py-xs) var(--ply-control-px-xs);
100
103
  vertical-align: baseline;
101
104
  }
102
105
 
@@ -31,6 +31,16 @@ $btn-secondary-dark-active: #bebebe;
31
31
  --ply-bg-surface-alt: #f4f4f4;
32
32
  --ply-bg-muted: #e0e0e0;
33
33
 
34
+ // Inverse surface = the body text color (flips opposite the body automatically).
35
+ // Referencing the parent vars means a themer who changes the text color gets the
36
+ // inverse surface for free, or can override these directly to manage independently.
37
+ --ply-bg-inverse: var(--ply-color-body);
38
+ --ply-layer-inverse-0: var(--ply-color-body);
39
+ --ply-layer-inverse-1: var(--ply-color-secondary);
40
+
41
+ // Absolute black — stays #000 in every mode/theme (intentionally not derived)
42
+ --ply-color-black: #000000;
43
+
34
44
  // Text
35
45
  --ply-color-body: #161616;
36
46
  --ply-color-headings: #161616;
@@ -81,8 +91,42 @@ $btn-secondary-dark-active: #bebebe;
81
91
  --ply-btn-secondary-bg-hover: color-mix(in oklch, var(--ply-btn-secondary-bg), black 15%);
82
92
  --ply-btn-secondary-bg-active: #{$btn-secondary-light-active};
83
93
  --ply-btn-secondary-bg-active: color-mix(in oklch, var(--ply-btn-secondary-bg), black 25%);
84
- --ply-border-radius: #{variables.$border-radius};
85
- --ply-btn-border-radius: #{variables.$button-radius};
94
+
95
+ // Border radius scale
96
+ --ply-radius-none: 0;
97
+ --ply-radius-xs: 0.125rem; // 2px
98
+ --ply-radius-sm: 0.25rem; // 4px
99
+ --ply-radius-md: 0.5rem; // 8px
100
+ --ply-radius-lg: 0.75rem; // 12px
101
+ --ply-radius-xl: 1rem; // 16px
102
+ --ply-radius-full: 9999px; // pill / circle
103
+
104
+ // Semantic component radius aliases — components consume these, themers can override either layer
105
+ --ply-border-radius: var(--ply-radius-sm);
106
+ --ply-btn-border-radius: var(--ply-radius-full);
107
+ --ply-label-radius: var(--ply-radius-sm); // labels: small radius by default
108
+ --ply-badge-radius: var(--ply-radius-full); // badges: pill by default
109
+
110
+ // Control sizing scale — shared by inputs, buttons, selects, textareas so a given
111
+ // size produces the same height across every form control. Height is emergent
112
+ // (font-size + vertical padding + line-height), never a fixed dimension.
113
+ --ply-control-font-lg: 1.125rem; // 18px
114
+ --ply-control-font: 1rem; // 16px
115
+ --ply-control-font-sm: 0.875rem; // 14px
116
+ --ply-control-font-xs: 0.75rem; // 12px
117
+ --ply-control-py-lg: 0.875rem; // 14px
118
+ --ply-control-py: 0.625rem; // 10px
119
+ --ply-control-py-sm: 0.375rem; // 6px
120
+ --ply-control-py-xs: 0.25rem; // 4px
121
+ --ply-control-px-lg: 2rem; // 32px
122
+ --ply-control-px: 1.5rem; // 24px
123
+ --ply-control-px-sm: 1rem; // 16px
124
+ --ply-control-px-xs: 0.75rem; // 12px
125
+ --ply-control-lh-lg: 1.75rem; // 28px
126
+ --ply-control-lh: 1.5rem; // 24px
127
+ --ply-control-lh-sm: 1.25rem; // 20px
128
+ --ply-control-lh-xs: 1rem; // 16px
129
+ --ply-input-radius: var(--ply-radius-sm);
86
130
 
87
131
  // Navigation
88
132
  --ply-nav-bg: var(--ply-bg-body);
@@ -182,6 +226,7 @@ $btn-secondary-dark-active: #bebebe;
182
226
  --ply-space-xs: 0.25rem;
183
227
  --ply-space-sm: 0.5rem;
184
228
  --ply-space-md: 0.75rem;
229
+ --ply-space: 1rem; // 16px — the default ply spacing unit
185
230
  --ply-space-lg: 1.5rem;
186
231
  --ply-space-xl: 2rem;
187
232
  --ply-space-xxl: 3rem;
@@ -194,6 +239,10 @@ $btn-secondary-dark-active: #bebebe;
194
239
  --ply-bg-surface-alt: #262626;
195
240
  --ply-bg-muted: #393939;
196
241
 
242
+ // --ply-bg-inverse / --ply-layer-inverse-* / --ply-color-black are not redefined here:
243
+ // the inverse vars reference --ply-color-body/secondary (which flip in this mixin), and
244
+ // black is mode-independent.
245
+
197
246
  // Text
198
247
  --ply-color-body: #f4f4f4;
199
248
  --ply-color-headings: #f4f4f4;
@@ -74,7 +74,9 @@
74
74
  border-radius: var(--ply-border-radius);
75
75
  display: block;
76
76
  width: 100%;
77
- padding: 0.5em 0.75em;
77
+ font-size: var(--ply-control-font);
78
+ line-height: var(--ply-control-lh);
79
+ padding: var(--ply-control-py) var(--ply-control-px);
78
80
  }
79
81
  }
80
82
 
@@ -264,26 +266,33 @@ input.input-on-black {
264
266
  }
265
267
  }
266
268
 
267
- /* Sizes */
269
+ /* Sizes — share the control sizing scale with buttons so a given size is the
270
+ same height across inputs, buttons, selects and textareas */
268
271
  .form .input-lg,
269
272
  input.input-lg[type],
270
273
  textarea.input-lg,
271
274
  select.input-lg {
272
- font-size: variables.$font-size-xl;
275
+ font-size: var(--ply-control-font-lg);
276
+ line-height: var(--ply-control-lh-lg);
277
+ padding: var(--ply-control-py-lg) var(--ply-control-px-lg);
273
278
  }
274
279
 
275
280
  .form .input-sm,
276
281
  input.input-sm[type],
277
282
  textarea.input-sm,
278
283
  select.input-sm {
279
- font-size: variables.$font-size-small;
284
+ font-size: var(--ply-control-font-sm);
285
+ line-height: var(--ply-control-lh-sm);
286
+ padding: var(--ply-control-py-sm) var(--ply-control-px-sm);
280
287
  }
281
288
 
282
289
  .form .input-xs,
283
290
  input.input-xs[type],
284
291
  textarea.input-xs,
285
292
  select.input-xs {
286
- font-size: variables.$font-size-smaller;
293
+ font-size: var(--ply-control-font-xs);
294
+ line-height: var(--ply-control-lh-xs);
295
+ padding: var(--ply-control-py-xs) var(--ply-control-px-xs);
287
296
  }
288
297
 
289
298
  /* Append & Prepend */
@@ -394,7 +403,7 @@ select.input-xs {
394
403
  }
395
404
  }
396
405
 
397
- /* Select */
406
+ // Select — the native dropdown / picker for choosing one option from a list
398
407
  .form select {
399
408
  appearance: none;
400
409
  background-color: var(--ply-color-input-bg);
@@ -15,13 +15,16 @@
15
15
  font-weight: normal;
16
16
  text-transform: uppercase;
17
17
  }
18
+ .label {
19
+ border-radius: var(--ply-label-radius);
20
+ }
18
21
  .label-outline {
19
22
  background: none;
20
23
  border: 1px solid var(--ply-color-body, colors.$color-black);
21
24
  padding: 3px 6px 2px 6px;
22
25
  }
23
26
  .badge {
24
- border-radius: 15px;
27
+ border-radius: var(--ply-badge-radius);
25
28
  }
26
29
  .badge-small {
27
30
  font-size: variables.$font-size-smaller;
@@ -275,23 +275,31 @@ summary {
275
275
  font-weight: 600;
276
276
  padding: 0.25rem 0;
277
277
  list-style: none;
278
+ display: flex;
279
+ align-items: center;
278
280
 
279
281
  &::marker,
280
282
  &::-webkit-details-marker {
281
283
  display: none;
282
284
  }
283
285
 
284
- &::before {
285
- content: '\25B6';
286
- display: inline-block;
287
- margin-right: 0.5rem;
288
- font-size: 0.75em;
286
+ // Caret sits on the right and rotates when open. Drawn with borders (symmetric
287
+ // bounding box) so the 180° rotation pivots cleanly with no vertical shift.
288
+ &::after {
289
+ content: '';
290
+ flex: none;
291
+ margin-left: auto;
292
+ width: 0;
293
+ height: 0;
294
+ border-left: 0.3em solid transparent;
295
+ border-right: 0.3em solid transparent;
296
+ border-top: 0.35em solid var(--ply-color-secondary);
289
297
  transition: transform 0.15s ease;
290
298
  }
291
299
  }
292
300
 
293
- details[open] > summary::before {
294
- transform: rotate(90deg);
301
+ details[open] > summary::after {
302
+ transform: rotate(180deg);
295
303
  }
296
304
 
297
305
  details[open] > summary {