@cityofportland/components-react 1.0.0-alpha.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/README.md ADDED
@@ -0,0 +1,278 @@
1
+ # Portland Component Library
2
+
3
+ [Visit Storybook](https://egovpdx.github.io/portland-component-library)
4
+
5
+ A React component library for Portland.gov, built with design tokens from Figma and based on the USWDS design system.
6
+
7
+ ## Usage
8
+
9
+ Install the library in your project:
10
+
11
+ ```bash
12
+ pnpm add @cityofportland/component-library
13
+ ```
14
+
15
+ ### Component-Level Imports (Recommended)
16
+
17
+ This approach provides optimal tree shaking by allowing you to import only the components and styles you need, resulting in the smallest possible bundle size.
18
+
19
+ 1. **Import the component:**
20
+
21
+ ```jsx
22
+ import { Button } from "@cityofportland/component-library/components/Button";
23
+ ```
24
+
25
+ 2. **Import the component's stylesheet:**
26
+
27
+ ```jsx
28
+ import "@cityofportland/component-library/components/Button/style.css";
29
+ ```
30
+
31
+ ### Selective Theme Loading
32
+
33
+ You can import a specific theme to style your application. Choose one of the following:
34
+
35
+ ```jsx
36
+ // PGOV Theme (Default)
37
+ import "@cityofportland/component-library/themes/pgov";
38
+
39
+ // PGOV Dark Theme
40
+ import "@cityofportland/component-library/themes/pgov-dark";
41
+
42
+ // USWDS Default Theme
43
+ import "@cityofportland/component-library/themes/uswds-default";
44
+ ```
45
+
46
+ ### Using Design Tokens
47
+
48
+ You can import the design tokens as a JavaScript object to use in your own custom components and styling.
49
+
50
+ ```jsx
51
+ import { designTokens } from "@cityofportland/component-library/tokens";
52
+
53
+ const MyCustomComponent = () => (
54
+ <div
55
+ style={{
56
+ backgroundColor: designTokens.color.primary.medium,
57
+ padding: designTokens.spacing.md,
58
+ }}
59
+ >
60
+ Hello, World!
61
+ </div>
62
+ );
63
+ ```
64
+
65
+ ### Dynamic Theme Loading
66
+
67
+ For applications that need to switch themes on the fly (e.g., a light/dark mode toggle), you can use the `themeLoader`.
68
+
69
+ ```jsx
70
+ import { loadTheme } from "@cityofportland/component-library/themeLoader";
71
+
72
+ const ThemeToggleButton = ({ theme, setTheme }) => {
73
+ const toggleTheme = async () => {
74
+ const newTheme = theme === "pgov" ? "pgov-dark" : "pgov";
75
+ await loadTheme(newTheme);
76
+ setTheme(newTheme);
77
+ };
78
+
79
+ return <button onClick={toggleTheme}>Toggle Theme</button>;
80
+ };
81
+ ```
82
+
83
+ ## Contributing to the Library
84
+
85
+ ### Quick Start
86
+
87
+ ```bash
88
+ # Clone the repository
89
+ git clone https://github.com/eGovPDX/portland-design-system.git
90
+ cd portland-component-library
91
+
92
+ # Install dependencies (using pnpm)
93
+ pnpm install
94
+
95
+ # Start Storybook
96
+ pnpm run storybook
97
+ ```
98
+
99
+ Storybook will open in your default browser at [http://localhost:6006](http://localhost:6006)
100
+
101
+ ## Prerequisites
102
+
103
+ - [Node.js](https://nodejs.org/) (v18 or higher)
104
+ - [pnpm](https://pnpm.io/) (v8 or higher)
105
+
106
+ To install pnpm:
107
+
108
+ ```bash
109
+ npm install -g pnpm
110
+ ```
111
+
112
+ ## Available Scripts
113
+
114
+ - `pnpm run storybook` - Start Storybook development server
115
+ - `pnpm run build` - Build the component library
116
+ - `pnpm run build-storybook` - Build Storybook for production
117
+ - `pnpm test` - Run tests
118
+ - `pnpm run lint` - Run ESLint
119
+ - `pnpm run prepare` - Build the library (runs automatically on install)
120
+
121
+ ## Project Structure
122
+
123
+ ```
124
+ portland-component-library/
125
+ ├── src/
126
+ │ ├── components/ # React components
127
+ │ │ ├── Accordion/ # Accordion content sections
128
+ │ │ ├── Alert/ # Alert messages and notifications
129
+ │ │ ├── Banner/ # Government website banner
130
+ │ │ ├── Breadcrumbs/# Navigation breadcrumbs
131
+ │ │ ├── Button/ # Button components
132
+ │ │ ├── ColorSwatch/# Color display and documentation
133
+ │ │ ├── Contacts/ # Contact information display
134
+ │ │ ├── Footer/ # Site footer with accessibility information
135
+ │ │ ├── Header/ # Generic USWDS Header wrapper with optional extended layout
136
+ │ │ ├── HeroGlobal/ # Global hero section with image and call-to-action
137
+ │ │ ├── HeroHomepage/# Homepage hero section
138
+ │ │ ├── Identifier/ # Agency identifier component
139
+ │ │ ├── LanguageSelector/ # Language selection dropdown component
140
+ │ │ ├── Modal/ # Modal dialog component
141
+ │ │ ├── PageTemplate/# Page template
142
+ │ │ ├── Pagination/ # USWDS-compliant pagination component
143
+ │ │ ├── Person/ # Profile block for individuals with avatar, name, role, and contact info
144
+ │ │ ├── PGOVHeader/ # Portland.gov navigation header
145
+ │ │ ├── ProcessSteps/# Process step indicators
146
+ │ │ ├── Search/ # Search input component
147
+ │ │ ├── SideNav/ # Side navigation
148
+ │ │ ├── SkipNav/ # Keyboard accessibility
149
+ │ │ ├── Spacing/ # Spacing utilities
150
+ │ │ ├── StepIndicator/# Horizontal step indicator
151
+ │ │ ├── SummaryBox/ # Summary information display
152
+ │ │ ├── Tag/ # Tag component for labeling and categorization
153
+ │ │ ├── Table/ # Table component for displaying tabular data
154
+ │ │ ├── Tooltip/ # Tooltip component
155
+ │ │ ├── Typography/ # Text components and styles
156
+ │ │ ├── Card/ # Card component for displaying content in a styled container
157
+ │ │ ├── CardFlag/ # Card component with media and content layout
158
+ │ │ ├── CardGrid/ # Grid layout for Card components
159
+ │ │ ├── Dropdown/ # Accessible custom dropdown/select component
160
+ │ │ ├── ExternalLinkIcon.jsx # External link icon component
161
+ │ │ ├── PopoverWithCard/# Popover for displaying interactive Card content
162
+ │ │ ├── RadioButtons/ # Accessible radio button component with multiple variants
163
+ │ │ ├── TextArea/ # Text area component for multi-line text input
164
+ │ │ ├── TextInput/ # Text input component with validation and states
165
+ │ │ └── Checkbox/ # Checkbox component allowing multiple selections from a list
166
+ │ ├── images/ # Image assets
167
+ │ └── styles/ # SCSS styles and themes
168
+ ├── .storybook/ # Storybook configuration
169
+ ├── __mocks__/ # Jest mocks
170
+ └── dist/ # Built component library
171
+ ```
172
+
173
+ ## Components
174
+
175
+ The library includes a comprehensive set of components for building Portland.gov pages:
176
+
177
+ ### Navigation Components
178
+
179
+ - **Banner** - Official government website banner
180
+ - **Header** - Generic USWDS Header wrapper with optional extended layout and navigation slots
181
+ - **PGOVHeader** - Portland.gov navigation component based on USWDS Header
182
+ - **Footer** - Site footer with accessibility information
183
+ - **Identifier** - Agency identifier component displaying parent agency and required policy links
184
+ - **SkipNav** - Keyboard accessibility enhancement
185
+ - **SideNav** - Side navigation component
186
+ - **Breadcrumbs** - Navigation breadcrumbs component
187
+ - **Pagination** - USWDS-compliant pagination for navigating paginated content
188
+
189
+ ### Interactive Components
190
+
191
+ - **Accordion** - Expandable content sections with multiple variants
192
+ - **Button** - Button components
193
+ - **ButtonGroup** - Group of related buttons, with default and segmented variants
194
+ - **Dropdown** - Accessible custom dropdown/select component
195
+ - **Modal** - Accessible modal dialog component
196
+ - **Tag** - Tag component for labeling and categorization
197
+
198
+ ### Layout Components
199
+
200
+ - **PageTemplate** - Complete page template with Banner, PGOVHeader, Footer, and SkipNav
201
+ - **HeroGlobal** - Global hero section with image and call-to-action
202
+ - **HeroHomepage** - Homepage hero section with search and popular links
203
+ - **SummaryBox** - Summary information display
204
+ - **Card** - Card component for displaying content
205
+ - **CardFlag** - Card component with media and content layout
206
+ - **CardGrid** - Grid layout for Card components
207
+
208
+ ### Form Components
209
+
210
+ - **Search** - Search input component with variants
211
+ - **TextArea** - Text area component for multi-line text input
212
+ - **TextInput** - Text input component with validation and states
213
+ - **RadioButtons** - Accessible radio button component with multiple variants
214
+ - **Checkbox** - Checkbox component allowing users to select one or more options from a list
215
+ - **LanguageSelector** - Language selection dropdown for switching site language, with accessibility and theme support
216
+
217
+ ### Content Components
218
+
219
+ - **Typography** - Text components and styles
220
+ - **Alert** - Alert messages and notifications
221
+ - **Contacts** - Contact information display
222
+ - **Person** - Profile block for individuals with avatar, name, role, department, contact actions, meta, and tags
223
+ - **ProcessSteps** - Process step indicators
224
+ - **StepIndicator** - Horizontal step indicator for multi-step processes
225
+ - **Tooltip** - Tooltip component
226
+ - **PopoverWithCard** - Popover for displaying interactive Card content
227
+ - **Table** - Table component for displaying tabular data with sorting, striping, sticky headers, scrollable and stacked (responsive) layouts.
228
+
229
+ ### Design System Components
230
+
231
+ - **ColorSwatch** - Color display and documentation
232
+ - **Spacing** - Spacing utilities and documentation
233
+
234
+ ## Documentation
235
+
236
+ Full documentation is available in Storybook:
237
+
238
+ 1. Start Storybook with `pnpm run storybook`
239
+ 2. Open [http://localhost:6006](http://localhost:6006)
240
+ 3. Browse components in the sidebar
241
+
242
+ Key documentation sections:
243
+
244
+ - Introduction - Overview and getting started
245
+ - Components - Detailed documentation for each component
246
+ - Design Tokens - Typography, colors, and spacing
247
+ - Theme Support - Light and dark mode support
248
+ - Color System - Comprehensive color palettes
249
+
250
+ ## Design System
251
+
252
+ This component library uses the PGOV theme based on the Portland.gov design system, with design tokens managed in a separate project at [github.com/eGovPDX/design-tokens](https://github.com/eGovPDX/design-tokens).
253
+
254
+ Features:
255
+
256
+ - Built on USWDS (U.S. Web Design System)
257
+ - Accessible by default
258
+ - Responsive design
259
+ - Dark mode support
260
+ - Comprehensive design tokens
261
+
262
+ ## Contributing
263
+
264
+ 1. Fork the repository
265
+ 2. Create a feature branch
266
+ 3. Make your changes
267
+ 4. Submit a pull request
268
+
269
+ Please ensure your changes:
270
+
271
+ - Follow the existing code style
272
+ - Include appropriate tests
273
+ - Update documentation as needed
274
+ - Pass all CI checks
275
+
276
+ ## License
277
+
278
+ ISC License - See [LICENSE](LICENSE) for details.
package/dist/box.css ADDED
@@ -0,0 +1 @@
1
+ @layer components{.box.box--default.box--subtle{border-color:var(--border-color-standard-default-subtle,#dfe1e2);background-color:var(--background-color-standard-default-subtle,#fff);color:var(--text-color-standard-default-strong,#070708)}.box.box--default.box--moderate{border-color:var(--border-color-standard-default-subtle,#dfe1e2);background-color:var(--background-color-standard-default-moderate,#f7f9fa);color:var(--text-color-standard-default-strong,#070708)}.box.box--default.box--emphasis{border-color:var(--border-color-standard-default-emphasis,#71767a);background-color:var(--background-color-standard-default-emphasis,#dfe1e2);color:var(--text-color-standard-default-strong,#070708)}.box.box--default.box--strong{border-color:var(--border-color-standard-default-emphasis,#71767a);background-color:var(--background-color-standard-default-strong,#a9aeb1);color:var(--text-color-standard-default-strong,#070708)}.box.box--primary.box--subtle{border-color:var(--border-color-primary-subtle,#aacdec);background-color:var(--background-color-primary-subtle,#d9e8f6);color:var(--text-color-standard-default-strong,#070708)}.box.box--primary.box--moderate{border-color:var(--border-color-primary-subtle,#aacdec);background-color:var(--background-color-primary-moderate,#005ea2);color:var(--text-color-standard-inverse-subtle,#fff)}.box.box--primary.box--emphasis{border-color:var(--border-color-primary-strong,#1f303e);background-color:var(--background-color-primary-emphasis,#274863);color:var(--text-color-standard-inverse-subtle,#fff)}.box.box--primary.box--strong{border-color:var(--border-color-primary-emphasis,#274863);background-color:var(--background-color-primary-strong,#1f303e);color:var(--text-color-standard-inverse-subtle,#fff)}.box.box--secondary.box--subtle{border-color:var(--border-color-secondary-subtle,#a9aeb1);background-color:var(--background-color-secondary-subtle,#f7f9fa);color:var(--text-color-standard-default-strong,#070708)}.box.box--secondary.box--moderate{border-color:var(--border-color-secondary-subtle,#a9aeb1);background-color:var(--background-color-secondary-moderate,#dfe1e2);color:var(--text-color-standard-default-strong,#070708)}.box.box--secondary.box--emphasis{border-color:var(--border-color-secondary-emphasis,#3d4551);background-color:var(--background-color-secondary-emphasis,#a9aeb1);color:var(--text-color-standard-default-strong,#070708)}.box.box--secondary.box--strong{border-color:var(--border-color-secondary-emphasis,#3d4551);background-color:var(--background-color-secondary-strong,#71767a);color:var(--text-color-standard-fixed-light,#fff)}.box.box--success.box--subtle{border-color:var(--border-color-success-subtle,#b8d293);background-color:var(--background-color-success-subtle,#eaf4dd);color:var(--text-color-standard-default-strong,#070708)}.box.box--success.box--moderate{border-color:var(--border-color-success-moderate,#719f2a);background-color:var(--background-color-success-moderate,#b8d293);color:var(--text-color-standard-fixed-dark,#070708)}.box.box--success.box--emphasis{border-color:var(--border-color-success-emphasis,#466c04);background-color:var(--background-color-success-emphasis,#719f2a);color:var(--text-color-standard-fixed-dark,#070708)}.box.box--success.box--strong{border-color:var(--border-color-success-strong,#243413);background-color:var(--background-color-success-strong,#466c04);color:var(--text-color-standard-inverse-subtle,#fff)}.box.box--danger.box--subtle{border-color:var(--border-color-danger-subtle,#fd8ba0);background-color:var(--background-color-danger-subtle,#f3e1e4);color:var(--text-color-standard-default-strong,#070708)}.box.box--danger.box--moderate{border-color:var(--border-color-danger-moderate,#b41d39);background-color:var(--background-color-danger-moderate,#fd8ba0);color:var(--text-color-standard-default-strong,#070708)}.box.box--danger.box--emphasis{border-color:var(--border-color-danger-emphasis,#832133);background-color:var(--background-color-danger-emphasis,#b41d39);color:var(--text-color-standard-fixed-light,#fff)}.box.box--danger.box--strong{border-color:var(--border-color-danger-strong,#832133);background-color:var(--background-color-danger-strong,#4f1c24);color:var(--text-color-standard-inverse-subtle,#fff)}.box.box--warning.box--subtle{border-color:var(--border-color-warning-moderate,#ffbe2e);background-color:var(--background-color-warning-subtle,#fef0c8);color:var(--text-color-standard-default-strong,#070708)}.box.box--warning.box--moderate{border-color:var(--border-color-warning-moderate,#ffbe2e);background-color:var(--background-color-warning-moderate,#ffe396);color:var(--text-color-standard-fixed-dark,#070708)}.box.box--warning.box--emphasis{border-color:var(--border-color-warning-emphasis,#c2850c);background-color:var(--background-color-warning-emphasis,#ffbe2e);color:var(--text-color-standard-fixed-dark,#070708)}.box.box--warning.box--strong{border-color:var(--border-color-warning-strong,#7a591a);background-color:var(--background-color-warning-strong,#3b2b15);color:var(--text-color-standard-inverse-subtle,#fff)}.box.box--info.box--subtle{border-color:var(--border-color-info-subtle,#99deea);background-color:var(--background-color-info-subtle,#e7f6f8);color:var(--text-color-standard-default-strong,#070708)}.box.box--info.box--moderate{border-color:var(--border-color-info-emphasis,#449dac);background-color:var(--background-color-info-moderate,#99deea);color:var(--text-color-standard-fixed-dark,#070708)}.box.box--info.box--emphasis{border-color:var(--border-color-info-emphasis,#449dac);background-color:var(--background-color-info-emphasis,#5dc0d1);color:var(--text-color-standard-fixed-dark,#070708)}.box.box--info.box--strong{border-color:var(--border-color-info-moderate,#5dc0d1);background-color:var(--background-color-info-strong,#168092);color:var(--text-color-standard-inverse-subtle,#fff)}.box.box--disabled.box--subtle{border-color:var(--border-color-disabled-subtle,#dfe1e2);background-color:var(--background-color-disabled-subtle,#f7f9fa);color:var(--text-color-disabled-strong,#2d2e2f)}.box.box--disabled.box--moderate{border-color:var(--border-color-disabled-moderate,#a9aeb1);background-color:var(--background-color-disabled-moderate,#dfe1e2);color:var(--text-color-disabled-strong,#2d2e2f)}.box.box--disabled.box--emphasis{border-color:var(--border-color-disabled-emphasis,#8d9297);background-color:var(--background-color-disabled-emphasis,#a9aeb1);color:var(--text-color-disabled-strong,#2d2e2f)}.box.box--disabled.box--strong{border-color:var(--border-color-disabled-emphasis,#8d9297);background-color:var(--background-color-disabled-strong,#565c65);color:var(--text-color-disabled-subtle,#dfe1e2)}.box.box--fixed.box--light{border-color:var(--border-color-fixed-light,#fff);background-color:var(--background-color-fixed-light,#fff);color:var(--text-color-standard-fixed-dark,#070708)}.box.box--fixed.box--dark{border-color:var(--border-color-fixed-dark,#070708);background-color:var(--background-color-fixed-dark,#070708);color:var(--text-color-standard-fixed-light,#fff)}}
package/dist/box.es.js ADDED
@@ -0,0 +1,57 @@
1
+ import { j as c } from "./index-CdrO5QDC.js";
2
+ const t = [
3
+ "subtle",
4
+ "moderate",
5
+ "emphasis",
6
+ "strong"
7
+ ], i = /* @__PURE__ */ new Map([
8
+ ["default", t],
9
+ ["primary", t],
10
+ ["secondary", t],
11
+ ["success", t],
12
+ ["danger", t],
13
+ ["warning", t],
14
+ ["info", t],
15
+ ["disabled", t],
16
+ ["fixed", ["dark", "light"]]
17
+ ]), l = (e, s) => {
18
+ const n = [e, s];
19
+ return !e || !s ? [void 0, void 0] : i.has(e) ? i.get(e)?.includes(s) ? n : (console.error(`[Box component] '${s}' is not a valid variant for color '${e}'.`), [void 0, void 0]) : (console.error(`[Box component] '${e}' is not a valid box color.`), [void 0, void 0]);
20
+ };
21
+ function m(...e) {
22
+ const s = e.flat().map((n) => typeof n == "string" ? n : "").filter(Boolean).reduce((n, o) => n.add(o), /* @__PURE__ */ new Set());
23
+ return Array.from(s).join(" ");
24
+ }
25
+ function x({
26
+ className: e = "",
27
+ color: s,
28
+ variant: n
29
+ }) {
30
+ return m(
31
+ "box",
32
+ s ? `box--${s}` : "",
33
+ n ? `box--${n}` : "",
34
+ e
35
+ );
36
+ }
37
+ const b = ({
38
+ as: e = "div",
39
+ border: s,
40
+ children: n,
41
+ color: o,
42
+ variant: d,
43
+ className: r,
44
+ ...u
45
+ }) => {
46
+ const a = e || "div";
47
+ [o, d] = l(o, d);
48
+ const f = x({
49
+ className: r,
50
+ color: o,
51
+ variant: d
52
+ });
53
+ return /* @__PURE__ */ c.jsx(a, { className: f, ...u, children: n });
54
+ };
55
+ export {
56
+ b as Box
57
+ };
@@ -0,0 +1 @@
1
+ @layer properties{@supports (((-webkit-hyphens:none)) and (not (margin-trim:inline))) or ((-moz-orient:inline) and (not (color:rgb(from red r g b)))){*,:before,:after{--tw-font-weight:initial;--tw-outline-style:solid;--tw-border-style:solid}::backdrop{--tw-font-weight:initial;--tw-outline-style:solid;--tw-border-style:solid}}}@layer components{.button{border-radius:var(--radius-md,.25rem);padding-inline:var(--spacing-lg,1.25rem);padding-block:var(--spacing-sm,.75rem);justify-content:center;align-items:center;gap:var(--spacing-xs,.5rem);--tw-font-weight:var(--font-weight-bold,700);font-weight:var(--font-weight-bold,700);cursor:pointer;display:inline-flex}.button:focus{outline-style:var(--tw-outline-style);outline-offset:4px;outline-width:4px;outline-color:var(--color-primary-vivid,#005ea2)}.button:disabled{cursor:not-allowed;background-color:var(--color-disabled-lighter,#dfe1e2);color:var(--text-color-disabled-emphasis,#a9aeb1)}.button--outline{border-style:var(--tw-border-style);border-width:var(--border-width-sm,.0625rem)}.button--primary{background-color:var(--background-color-primary-moderate,#005ea2);color:var(--text-color-standard-inverse-subtle,#fff)}@media(hover:hover){.button--primary:hover{background-color:var(--background-color-primary-strong,#1f303e)}}.button--primary:active{background-color:var(--background-color-primary-emphasis,#274863)}.button--primary:focus-visible:active{background-color:var(--background-color-primary-emphasis,#274863)}.button--primary.button--outline{border-color:var(--border-color-primary-moderate,#005ea2);background-color:var(--background-color-standard-default-subtle,#fff);color:var(--text-color-primary-strong,#1f303e)}@media(hover:hover){.button--primary.button--outline:hover{border-color:var(--border-color-primary-strong,#1f303e)}}.button--primary.button--outline:active{border-color:var(--border-color-primary-emphasis,#274863)}.button--secondary{background-color:var(--background-color-secondary-moderate,#dfe1e2);color:var(--text-color-standard-default-strong,#070708)}@media(hover:hover){.button--secondary:hover{background-color:var(--background-color-secondary-strong,#71767a);color:var(--text-color-standard-fixed-light,#fff)}}.button--secondary:active{background-color:var(--background-color-secondary-emphasis,#a9aeb1);color:var(--text-color-standard-default-strong,#070708)}.button--secondary:focus-visible{background-color:var(--background-color-secondary-emphasis,#a9aeb1)}.button--secondary.button--outline{border-color:var(--border-color-secondary-moderate,#71767a);background-color:var(--background-color-standard-default-subtle,#fff);color:var(--text-color-standard-default-emphasis,#1c1d1f)}@media(hover:hover){.button--secondary.button--outline:hover{border-color:var(--border-color-secondary-strong,#1c1d1f)}}.button--secondary.button--outline:active{border-color:var(--border-color-secondary-emphasis,#3d4551)}.button--danger{background-color:var(--background-color-danger-emphasis,#b41d39);color:var(--text-color-standard-inverse-subtle,#fff)}@media(hover:hover){.button--danger:hover{background-color:var(--background-color-danger-strong,#4f1c24)}}.button--danger:active{background-color:var(--background-color-danger-emphasis,#b41d39)}.button--danger:focus-visible{background-color:var(--background-color-danger-emphasis,#b41d39)}.button--danger.button--outline{border-color:var(--border-color-danger-moderate,#b41d39);background-color:var(--background-color-standard-default-subtle,#fff);color:var(--text-color-danger-strong,#4f1c24)}@media(hover:hover){.button--danger.button--outline:hover{border-color:var(--border-color-danger-strong,#832133)}}.button--danger.button--outline:active{border-color:var(--border-color-danger-emphasis,#832133)}.button--inverse{background-color:var(--background-color-standard-inverse-moderate,#1c1d1f);color:var(--text-color-standard-inverse-subtle,#fff)}@media(hover:hover){.button--inverse:hover{background-color:var(--background-color-standard-inverse-subtle,#070708)}}.button--inverse:active{background-color:var(--background-color-standard-inverse-emphasis,#565c65)}.button--unstyled{--tw-font-weight:var(--font-weight-regular,400);font-weight:var(--font-weight-regular,400);color:var(--text-color-primary-moderate,#005ea2);background-color:#0000;text-decoration-line:underline}.button--default{font-size:var(--text-body-md,.976875rem)}.button--small{font-size:var(--text-body-sm,.85625rem)}.button--big{font-size:var(--text-body-lg,1.34375rem)}}@property --tw-font-weight{syntax:"*";inherits:false}@property --tw-outline-style{syntax:"*";inherits:false;initial-value:solid}@property --tw-border-style{syntax:"*";inherits:false;initial-value:solid}
@@ -0,0 +1,35 @@
1
+ import { j as n } from "./index-CdrO5QDC.js";
2
+ const j = ({
3
+ children: e = null,
4
+ variant: a = "primary",
5
+ size: i = "default",
6
+ disabled: t = !1,
7
+ type: p = "button",
8
+ left: u,
9
+ right: o,
10
+ className: r = "",
11
+ ...c
12
+ }) => {
13
+ function l() {
14
+ const s = ["button"];
15
+ return s.push(`button--${i}`), t || s.push(`button--${a}`), r && s.push(r), s;
16
+ }
17
+ return /* @__PURE__ */ n.jsxs(
18
+ "button",
19
+ {
20
+ type: p,
21
+ className: l().join(" "),
22
+ disabled: t,
23
+ "aria-disabled": t ? "true" : "false",
24
+ ...c,
25
+ children: [
26
+ u && /* @__PURE__ */ n.jsx("span", { children: u }),
27
+ e,
28
+ o && /* @__PURE__ */ n.jsx("span", { children: o })
29
+ ]
30
+ }
31
+ );
32
+ };
33
+ export {
34
+ j as Button
35
+ };