@vsn-ux/gaia-styles 0.6.0 → 0.6.1

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.
@@ -0,0 +1,57 @@
1
+ # Card
2
+
3
+ ## Visual Structure
4
+
5
+ ```
6
+ ga-card [--selectable|--disabled]
7
+ ```
8
+
9
+ ## Elements Hierarchy
10
+
11
+ ### Core Block
12
+
13
+ - `ga-card` - Main container for the entire card component
14
+
15
+ ### Modifiers
16
+
17
+ - `ga-card--selectable` - Makes the card interactive/clickable
18
+ - `ga-card--disabled` - Styles the card as disabled/non-interactive
19
+ - `ga-card--selected` - Styles the card as selected
20
+
21
+ ## Examples
22
+
23
+ ### Default
24
+
25
+ ```html
26
+ <div class="ga-card">
27
+ <h2 class="font-bold">Card title</h2>
28
+ <div>Card description</div>
29
+ </div>
30
+ ```
31
+
32
+ ### Selectable
33
+
34
+ ```html
35
+ <div role="button" tabindex="0" class="ga-card ga-card--selectable">
36
+ <h2 class="font-bold">Card title</h2>
37
+ <div>Card description</div>
38
+ </div>
39
+ ```
40
+
41
+ ### Selected
42
+
43
+ ```html
44
+ <div class="ga-card ga-card--selectable ga-card--selected">
45
+ <h2 class="font-bold">Card title</h2>
46
+ <div>Card description</div>
47
+ </div>
48
+ ```
49
+
50
+ ### Disabled
51
+
52
+ ```html
53
+ <div class="ga-card ga-card--disabled">
54
+ <h2 class="font-bold">Card title</h2>
55
+ <div>Card description</div>
56
+ </div>
57
+ ```
@@ -0,0 +1,112 @@
1
+ # Checkbox
2
+
3
+ ## Visual Structure
4
+
5
+ ```
6
+ ga-checkbox [--invalid]
7
+ ├── ga-checkbox__native
8
+ ├── ga-checkbox__marker
9
+ │ ├── ga-checkbox__marker__indicator-checked
10
+ │ └── ga-checkbox__marker__indicator-indeterminate
11
+ └── ga-checkbox__label (optional)
12
+ ```
13
+
14
+ ## Elements Hierarchy
15
+
16
+ ### Core Block
17
+
18
+ - `ga-checkbox` - Main container for the checkbox component
19
+
20
+ ### Mandatory Elements
21
+
22
+ - `ga-checkbox__native` - Native HTML input element (hidden visually)
23
+ - `ga-checkbox__marker` - Visual marker/box for the checkbox state
24
+ - `ga-checkbox__marker__indicator-checked` - Icon shown when checkbox is checked (use `CheckIcon` from Lucide icons)
25
+ - `ga-checkbox__marker__indicator-indeterminate` - Icon shown when checkbox is in indeterminate state (use `MinusIcon` from Lucide icons)
26
+
27
+ ### Optional Elements
28
+
29
+ - `ga-checkbox__label` - Text label for the checkbox
30
+
31
+ ### Modifiers
32
+
33
+ - `ga-checkbox--invalid` - Styles the checkbox to indicate an invalid/error state
34
+
35
+ ## Examples
36
+
37
+ ### Default
38
+
39
+ ```html
40
+ <label class="ga-checkbox">
41
+ <input type="checkbox" class="ga-checkbox__native" />
42
+ <div class="ga-checkbox__marker">
43
+ <!-- icon: check, size=12, class="ga-checkbox__marker__indicator-checked" -->
44
+ <!-- icon: minus, size=12, class="ga-checkbox__marker__indicator-indeterminate" -->
45
+ </div>
46
+ <div class="ga-checkbox__label">Option A</div>
47
+ </label>
48
+ ```
49
+
50
+ ### Checked
51
+
52
+ ```html
53
+ <label class="ga-checkbox">
54
+ <input type="checkbox" class="ga-checkbox__native" checked="" />
55
+ <div class="ga-checkbox__marker">
56
+ <!-- icon: check, size=12, class="ga-checkbox__marker__indicator-checked" -->
57
+ <!-- icon: minus, size=12, class="ga-checkbox__marker__indicator-indeterminate" -->
58
+ </div>
59
+ <div class="ga-checkbox__label">Option A</div>
60
+ </label>
61
+ ```
62
+
63
+ ### Indeterminate
64
+
65
+ ```html
66
+ <label class="ga-checkbox">
67
+ <input type="checkbox" class="ga-checkbox__native" />
68
+ <div class="ga-checkbox__marker">
69
+ <!-- icon: check, size=12, class="ga-checkbox__marker__indicator-checked" -->
70
+ <!-- icon: minus, size=12, class="ga-checkbox__marker__indicator-indeterminate" -->
71
+ </div>
72
+ <div class="ga-checkbox__label">Option A</div>
73
+ </label>
74
+ ```
75
+
76
+ ### Disabled
77
+
78
+ ```html
79
+ <label class="ga-checkbox">
80
+ <input type="checkbox" class="ga-checkbox__native" disabled="" checked="" />
81
+ <div class="ga-checkbox__marker">
82
+ <!-- icon: check, size=12, class="ga-checkbox__marker__indicator-checked" -->
83
+ <!-- icon: minus, size=12, class="ga-checkbox__marker__indicator-indeterminate" -->
84
+ </div>
85
+ <div class="ga-checkbox__label">Option A</div>
86
+ </label>
87
+ ```
88
+
89
+ ### Invalid
90
+
91
+ ```html
92
+ <label class="ga-checkbox ga-checkbox--invalid">
93
+ <input type="checkbox" class="ga-checkbox__native" required="" />
94
+ <div class="ga-checkbox__marker">
95
+ <!-- icon: check, size=12, class="ga-checkbox__marker__indicator-checked" -->
96
+ <!-- icon: minus, size=12, class="ga-checkbox__marker__indicator-indeterminate" -->
97
+ </div>
98
+ <div class="ga-checkbox__label">Option A</div>
99
+ </label>
100
+ ```
101
+
102
+ ### Nolabel
103
+
104
+ ```html
105
+ <div class="ga-checkbox">
106
+ <input type="checkbox" class="ga-checkbox__native" />
107
+ <div class="ga-checkbox__marker">
108
+ <!-- icon: check, size=12, class="ga-checkbox__marker__indicator-checked" -->
109
+ <!-- icon: minus, size=12, class="ga-checkbox__marker__indicator-indeterminate" -->
110
+ </div>
111
+ </div>
112
+ ```
@@ -0,0 +1,62 @@
1
+ # Container Utilities
2
+
3
+ Container utilities provide consistent layout margins across different screen sizes based on the Gaia Design System grid values.
4
+
5
+ ## Overview
6
+
7
+ The container system follows a mobile-first approach with responsive margins that align with your grid system:
8
+
9
+ <table>
10
+ <thead>
11
+ <tr>
12
+ <th>Breakpoint</th>
13
+ <th>Screen Size</th>
14
+ <th>Margin</th>
15
+ </tr>
16
+ </thead>
17
+ <tbody>
18
+ <tr>
19
+ <td>XS</td>
20
+ <td>0-839px</td>
21
+ <td>16px</td>
22
+ </tr>
23
+ <tr>
24
+ <td>S</td>
25
+ <td>840-1439px</td>
26
+ <td>24px</td>
27
+ </tr>
28
+ <tr>
29
+ <td>M</td>
30
+ <td>1440-1919px</td>
31
+ <td>32px</td>
32
+ </tr>
33
+ <tr>
34
+ <td>L</td>
35
+ <td>1920-2559px</td>
36
+ <td>40px</td>
37
+ </tr>
38
+ </tbody>
39
+ </table>
40
+
41
+ ## Usage
42
+
43
+ ### Responsive Container
44
+
45
+ Use `ga-container` for a responsive container that automatically adjusts margins based on screen size:
46
+
47
+ ```html
48
+ <div class="ga-container">
49
+ <h1>Your content here</h1>
50
+ </div>
51
+ ```
52
+
53
+ ## Integration with Components
54
+
55
+ These container utilities are designed to work seamlessly with other Gaia components:
56
+
57
+ ```html
58
+ <div class="ga-container">
59
+ <button class="ga-button ga-button--primary">Primary Button</button>
60
+ <p class="ga-text-body">Text content</p>
61
+ </div>
62
+ ```
@@ -0,0 +1,107 @@
1
+ # Datepicker
2
+
3
+ ## Visual Structure
4
+
5
+ ```
6
+ ga-datepicker
7
+ ├── ga-calendar...
8
+ └── ga-datepicker__footer
9
+ ga-datepicker-toggle
10
+ ```
11
+
12
+ ## Elements Hierarchy
13
+
14
+ ### Core Blocks
15
+
16
+ - `ga-datepicker` - Main container for the entire datepicker component
17
+ - `ga-datepicker-toggle` - Icon button to toggle the visibility of the datepicker to be used inside an input field
18
+
19
+ ### Optional Elements
20
+
21
+ - `ga-datepicker__footer` - Footer section with additional actions like "Today" button
22
+
23
+ ## Examples
24
+
25
+ ### Default
26
+
27
+ ```html
28
+ <div class="ga-datepicker">
29
+ <div class="ga-calendar">
30
+ <div class="ga-calendar__header">
31
+ <div class="ga-calendar__month-year">
32
+ <button type="button" class="ga-calendar__month-year-button">
33
+ Sep
34
+ <!-- icon: chevron-down, size=16, class="ga-icon" -->
35
+ </button>
36
+ <button type="button" class="ga-calendar__month-year-button">
37
+ 2025
38
+ <!-- icon: chevron-down, size=16, class="ga-icon" -->
39
+ </button>
40
+ </div>
41
+ <div class="ga-calendar__navigation">
42
+ <button type="button" class="ga-calendar__navigation-button">
43
+ <!-- icon: chevron-left, size=24, class="ga-icon" -->
44
+ </button>
45
+ <button type="button" class="ga-calendar__navigation-button">
46
+ <!-- icon: chevron-right, size=24, class="ga-icon" -->
47
+ </button>
48
+ </div>
49
+ </div>
50
+ <div class="ga-calendar__weekdays">
51
+ <div class="ga-calendar__weekday">Mo</div>
52
+ <div class="ga-calendar__weekday">Tu</div>
53
+ <div class="ga-calendar__weekday">We</div>
54
+ <div class="ga-calendar__weekday">Th</div>
55
+ <div class="ga-calendar__weekday">Fr</div>
56
+ <div class="ga-calendar__weekday">Sa</div>
57
+ <div class="ga-calendar__weekday">Su</div>
58
+ </div>
59
+ <div class="ga-calendar__selection ga-calendar__selection--day">
60
+ <div class="ga-calendar__day">1</div>
61
+ <div class="ga-calendar__day">2</div>
62
+ <div class="ga-calendar__day">3</div>
63
+ <div class="ga-calendar__day">4</div>
64
+ <div class="ga-calendar__day">5</div>
65
+ <div class="ga-calendar__day">6</div>
66
+ <div class="ga-calendar__day">7</div>
67
+ <div class="ga-calendar__day">8</div>
68
+ <div class="ga-calendar__day">9</div>
69
+ <div class="ga-calendar__day ga-calendar__day--special">10</div>
70
+ <div class="ga-calendar__day">11</div>
71
+ <div class="ga-calendar__day">12</div>
72
+ <div class="ga-calendar__day">13</div>
73
+ <div class="ga-calendar__day">14</div>
74
+ <div class="ga-calendar__day ga-calendar__day--current">15</div>
75
+ <div class="ga-calendar__day">16</div>
76
+ <div class="ga-calendar__day">17</div>
77
+ <div class="ga-calendar__day">18</div>
78
+ <div class="ga-calendar__day">19</div>
79
+ <div class="ga-calendar__day ga-calendar__day--selected">20</div>
80
+ <div class="ga-calendar__day">21</div>
81
+ <div class="ga-calendar__day">22</div>
82
+ <div class="ga-calendar__day">23</div>
83
+ <div class="ga-calendar__day">24</div>
84
+ <div class="ga-calendar__day">25</div>
85
+ <div class="ga-calendar__day">26</div>
86
+ <div class="ga-calendar__day">27</div>
87
+ <div class="ga-calendar__day">28</div>
88
+ <div class="ga-calendar__day">29</div>
89
+ <div class="ga-calendar__day">30</div>
90
+ </div>
91
+ </div>
92
+ <div class="ga-datepicker__footer text-center">
93
+ <button class="ga-button ga-button--secondary">Today</button>
94
+ </div>
95
+ </div>
96
+ ```
97
+
98
+ ### Input
99
+
100
+ ```html
101
+ <div class="ga-input">
102
+ <input type="text" value="2025-09-15" />
103
+ <button type="button" class="ga-datepicker-toggle">
104
+ <!-- icon: calendar-days, size=24 -->
105
+ </button>
106
+ </div>
107
+ ```
@@ -0,0 +1,152 @@
1
+ # Dropdown
2
+
3
+ ## Visual Structure
4
+
5
+ ```
6
+ ga-dropdown
7
+ ├── ga-dropdown__caption (optional)
8
+ ├── ga-dropdown__empty (optional)
9
+ ├── ga-dropdown__spinner (optional)
10
+ └── ga-dropdown__item [--selected|--disabled|--active]
11
+ └── ga-dropdown__item-label
12
+ ```
13
+
14
+ ## Elements Hierarchy
15
+
16
+ ### Core Block
17
+
18
+ - `ga-dropdown` - Main container for the entire dropdown component
19
+
20
+ ### Mandatory Elements
21
+
22
+ - `ga-dropdown__item` - Individual clickable/interactive dropdown option
23
+ - `ga-dropdown__item-label` - The primary text label identifying the dropdown action
24
+
25
+ ### Optional Elements
26
+
27
+ - `ga-dropdown__caption` - The heading/title of the dropdown section
28
+ - `ga-dropdown__empty` - Container for empty state content when no items are available
29
+ - `ga-dropdown__spinner` - Container for loading spinner when fetching items
30
+
31
+ ### Modifiers
32
+
33
+ - `ga-dropdown__item--selected` - Indicates the currently selected dropdown item
34
+ - `ga-dropdown__item--disabled` - Styles the dropdown item as disabled/non-interactive
35
+ - `ga-dropdown__item--disabled ga-dropdown__item--selected` - Combined state for a selected but disabled item
36
+ - `ga-dropdown__item--active` - Indicates the dropdown item is currently active/focused through keyboard
37
+
38
+ ## Examples
39
+
40
+ ### Basic
41
+
42
+ ```html
43
+ <div class="ga-dropdown">
44
+ <button class="ga-dropdown__item">
45
+ <div class="ga-dropdown__item-label">Item 1</div>
46
+ </button>
47
+ <button class="ga-dropdown__item">
48
+ <div class="ga-dropdown__item-label">Item 2</div>
49
+ </button>
50
+ <button class="ga-dropdown__item">
51
+ <div class="ga-dropdown__item-label">Item 3</div>
52
+ </button>
53
+ </div>
54
+ ```
55
+
56
+ ### With Title
57
+
58
+ ```html
59
+ <div class="ga-dropdown">
60
+ <div class="ga-dropdown__caption">Group A</div>
61
+ <button class="ga-dropdown__item">
62
+ <div class="ga-dropdown__item-label">Item 1</div>
63
+ </button>
64
+ <button class="ga-dropdown__item">
65
+ <div class="ga-dropdown__item-label">Item 2</div>
66
+ </button>
67
+ <button class="ga-dropdown__item">
68
+ <div class="ga-dropdown__item-label">Item 3</div>
69
+ </button>
70
+ </div>
71
+ ```
72
+
73
+ ### Statuses
74
+
75
+ ```html
76
+ <div class="ga-dropdown">
77
+ <button class="ga-dropdown__item ga-dropdown__item--selected">
78
+ <div class="ga-dropdown__item-label">Selected</div>
79
+ </button>
80
+ <button class="ga-dropdown__item ga-dropdown__item--active">
81
+ <div class="ga-dropdown__item-label">Active (non focused)</div>
82
+ </button>
83
+ <button class="ga-dropdown__item">
84
+ <div class="ga-dropdown__item-label">Default</div>
85
+ </button>
86
+ <button class="ga-dropdown__item ga-dropdown__item--disabled" disabled="">
87
+ <div class="ga-dropdown__item-label">Disabled</div>
88
+ </button>
89
+ <button
90
+ class="ga-dropdown__item ga-dropdown__item--disabled ga-dropdown__item--selected"
91
+ disabled=""
92
+ >
93
+ <div class="ga-dropdown__item-label">Disabled Selected</div>
94
+ </button>
95
+ </div>
96
+ ```
97
+
98
+ ### Overflow
99
+
100
+ ```html
101
+ <div class="ga-dropdown">
102
+ <div class="ga-dropdown__caption">Group A</div>
103
+ <button class="ga-dropdown__item">
104
+ <div class="ga-dropdown__item-label">Item 1</div>
105
+ </button>
106
+ <button class="ga-dropdown__item">
107
+ <div class="ga-dropdown__item-label">Item 2</div>
108
+ </button>
109
+ <button class="ga-dropdown__item">
110
+ <div class="ga-dropdown__item-label">Item 3</div>
111
+ </button>
112
+ <button class="ga-dropdown__item">
113
+ <div class="ga-dropdown__item-label">Item 4</div>
114
+ </button>
115
+ <button class="ga-dropdown__item">
116
+ <div class="ga-dropdown__item-label">Item 5</div>
117
+ </button>
118
+ <button class="ga-dropdown__item">
119
+ <div class="ga-dropdown__item-label">Item 6</div>
120
+ </button>
121
+ <button class="ga-dropdown__item">
122
+ <div class="ga-dropdown__item-label">Item 7</div>
123
+ </button>
124
+ <button class="ga-dropdown__item">
125
+ <div class="ga-dropdown__item-label">Item 8</div>
126
+ </button>
127
+ <button class="ga-dropdown__item">
128
+ <div class="ga-dropdown__item-label">Item 9</div>
129
+ </button>
130
+ <button class="ga-dropdown__item">
131
+ <div class="ga-dropdown__item-label">Item 10</div>
132
+ </button>
133
+ </div>
134
+ ```
135
+
136
+ ### Empty
137
+
138
+ ```html
139
+ <div class="ga-dropdown">
140
+ <div class="ga-dropdown__empty">No items found</div>
141
+ </div>
142
+ ```
143
+
144
+ ### Spinner
145
+
146
+ ```html
147
+ <div class="ga-dropdown">
148
+ <div class="ga-dropdown__spinner">
149
+ <div class="bg-neutral-30 h-4 w-4 rounded-full"></div>
150
+ </div>
151
+ </div>
152
+ ```
@@ -0,0 +1,101 @@
1
+ # Form Field
2
+
3
+ ## Visual Structure
4
+
5
+ ```
6
+ ga-form-field
7
+ ├── ga-form-field__label [--defined|--disabled]
8
+ │ ├── ga-form-field__label-text
9
+ │ └── ga-form-field__label-state (optional)
10
+ ├── [placeholder]
11
+ └── ga-form-field__info (optional)
12
+ ```
13
+
14
+ ## Elements Hierarchy
15
+
16
+ ### Core Block
17
+
18
+ - `ga-form-field` - Main container for the entire form field component
19
+
20
+ ### Mandatory Elements
21
+
22
+ - `ga-form-field__label` - Container for the label elements
23
+ - `ga-form-field__label-text` - The text content of the form field label
24
+ - `[placeholder]` - Insert form control here (e.g. `ga-input`, `ga-select`, etc.)
25
+
26
+ ### Optional Elements
27
+
28
+ - `ga-form-field__label-state` - Additional text for the label (e.g., "optional")
29
+ - `ga-form-field__info` - Container for additional information or validation messages
30
+
31
+ ### Modifiers
32
+
33
+ - `ga-form-field__label--defined` - Styles the label text with a dotted underline and interactive colors
34
+ - `ga-form-field__label--disabled` - Styles the label as disabled/non-interactive
35
+
36
+ ## Examples
37
+
38
+ ### Regular
39
+
40
+ ```html
41
+ <div class="ga-form-field">
42
+ <label class="ga-form-field__label" for="input1">
43
+ <span class="ga-form-field__label-text">Label</span>
44
+ </label>
45
+ <div class="ga-input">
46
+ <input id="input1" type="text" placeholder="Text" />
47
+ </div>
48
+ </div>
49
+ ```
50
+
51
+ ### With Info
52
+
53
+ ```html
54
+ <div class="ga-form-field">
55
+ <label class="ga-form-field__label" for="input2">
56
+ <span class="ga-form-field__label-text">Label</span>
57
+ </label>
58
+ <div class="ga-input">
59
+ <input id="input2" type="text" placeholder="Text" />
60
+ </div>
61
+ <div class="ga-form-field__info">
62
+ <!-- icon: triangle-alert, size=16, class="ga-icon" -->
63
+ Use special characters if available.
64
+ </div>
65
+ </div>
66
+ ```
67
+
68
+ ### Label With Definition
69
+
70
+ ```html
71
+ <div class="ga-form-field">
72
+ <label
73
+ class="ga-form-field__label ga-form-field__label--defined"
74
+ for="input3"
75
+ tabindex="0"
76
+ >
77
+ <span class="ga-form-field__label-text">Label</span>
78
+ <span class="ga-form-field__label-state">(optional)</span>
79
+ </label>
80
+ <div class="ga-input">
81
+ <input id="input3" type="text" placeholder="Text" />
82
+ </div>
83
+ </div>
84
+ ```
85
+
86
+ ### Disabled
87
+
88
+ ```html
89
+ <div class="ga-form-field">
90
+ <label
91
+ class="ga-form-field__label ga-form-field__label--defined ga-form-field__label--disabled"
92
+ for="input4"
93
+ >
94
+ <span class="ga-form-field__label-text">Label</span>
95
+ <span class="ga-form-field__label-state">(optional)</span>
96
+ </label>
97
+ <div class="ga-input">
98
+ <input id="input4" type="text" placeholder="Text" disabled="" />
99
+ </div>
100
+ </div>
101
+ ```
@@ -0,0 +1,84 @@
1
+ # Input
2
+
3
+ ## Visual Structure
4
+
5
+ ```
6
+ ga-input [--invalid|--success]
7
+ ├── [icon prefix] (optional)
8
+ ├── input
9
+ └── [icon suffix] (optional)
10
+ ```
11
+
12
+ ## Elements Hierarchy
13
+
14
+ ### Core Block
15
+
16
+ - `ga-input` - Main container for the entire input component
17
+
18
+ ### Mandatory Elements
19
+
20
+ - `input` - The native HTML input element
21
+
22
+ ### Optional Elements
23
+
24
+ - Icon prefix - An icon placed before the input text
25
+ - Icon suffix - An icon placed after the input text
26
+
27
+ ### Modifiers
28
+
29
+ - `ga-input--invalid` - Styles the input to indicate validation error
30
+ - `ga-input--success` - Styles the input to indicate successful validation
31
+
32
+ ## Examples
33
+
34
+ ### Regular
35
+
36
+ ```html
37
+ <div class="ga-input"><input type="text" placeholder="Placeholder" /></div>
38
+ ```
39
+
40
+ ### With Prefix Icon
41
+
42
+ ```html
43
+ <div class="ga-input">
44
+ <!-- icon: mail, size=24 -->
45
+ <input type="text" placeholder="Placeholder" />
46
+ </div>
47
+ ```
48
+
49
+ ### With Suffix Icon
50
+
51
+ ```html
52
+ <div class="ga-input">
53
+ <input type="text" placeholder="Placeholder" />
54
+ <!-- icon: circle-x, size=16 -->
55
+ </div>
56
+ ```
57
+
58
+ ### Disabled
59
+
60
+ ```html
61
+ <div class="ga-input">
62
+ <input type="text" placeholder="Placeholder" disabled="" />
63
+ </div>
64
+ <div class="ga-input">
65
+ <input type="text" placeholder="Placeholder" disabled="" value="Filled" />
66
+ </div>
67
+ ```
68
+
69
+ ### Invalid
70
+
71
+ ```html
72
+ <div class="ga-input ga-input--invalid">
73
+ <input type="text" placeholder="Placeholder" />
74
+ <!-- icon: triangle-alert, size=24 -->
75
+ </div>
76
+ ```
77
+
78
+ ### Success
79
+
80
+ ```html
81
+ <div class="ga-input ga-input--success">
82
+ <input type="text" placeholder="Placeholder" />
83
+ </div>
84
+ ```