@cscfi/csc-ui-react 4.0.0-alpha.1 → 4.0.0-alpha.10

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.
@@ -3,7 +3,7 @@
3
3
  * Manifest — do not edit. Regenerate with `pnpm run generate`.
4
4
  */
5
5
  import { type EventName } from '@lit/react';
6
- import { type CAccordionElement, type CAccordionElementEventMap, type CAccordionItemElement, type CAccordionItemElementEventMap, type CAlertElement, type CAutocompleteElement, type CAutocompleteElementEventMap, type CBadgeElement, type CButtonElement, type CButtonGroupElement, type CButtonGroupElementEventMap, type CCardElement, type CCardActionsElement, type CCardContentElement, type CCardTitleElement, type CCheckboxElement, type CCheckboxElementEventMap, type CCscLogoElement, type CDataTableElement, type CDataTableElementEventMap, type CDividerElement, type CIconElement, type CIconButtonElement, type CInputElement, type CLinkElement, type CListElement, type CListItemElement, type CListItemTitleElement, type CLoaderElement, type CLoginButtonElement, type CLoginButtonsElement, type CLoginCardElement, type CLoginCardActionsElement, type CLoginCardContentElement, type CLoginCardTitleElement, type CMainElement, type CMenuElement, type CMenuElementEventMap, type CMenuItemElement, type CMenuLabelElement, type CMessageElement, type CModalElement, type CModalElementEventMap, type CNavigationButtonElement, type COptionElement, type COptionValueElement, type COtpInputElement, type COtpInputElementEventMap, type CPageElement, type CPaginationElement, type CPaginationElementEventMap, type CProgressBarElement, type CRadioElement, type CRadioGroupElement, type CRadioGroupElementEventMap, type CSelectElement, type CSelectElementEventMap, type CSideNavigationElement, type CSideNavigationElementEventMap, type CSideNavigationItemElement, type CSideNavigationItemElementEventMap, type CSideNavigationTitleElement, type CSliderElement, type CSliderElementEventMap, type CSpinnerElement, type CStatusElement, type CStepElement, type CStepsElement, type CSubNavigationItemElement, type CSwitchElement, type CSwitchElementEventMap, type CTabElement, type CTabElementEventMap, type CTabButtonsElement, type CTabButtonsElementEventMap, type CTabItemElement, type CTabItemElementEventMap, type CTabItemsElement, type CTableElement, type CTabsElement, type CTabsElementEventMap, type CTagElement, type CTagElementEventMap, type CTagsElement, type CTextFieldElement, type CTextFieldElementEventMap, type CToastElement, type CToastElementEventMap, type CToastsElement, type CToolbarElement } from '@cscfi/csc-ui';
6
+ import { type CAccordionElement, type CAccordionElementEventMap, type CAccordionItemElement, type CAccordionItemElementEventMap, type CAlertElement, type CAlertElementEventMap, type CAutocompleteElement, type CAutocompleteElementEventMap, type CBadgeElement, type CButtonElement, type CButtonGroupElement, type CButtonGroupElementEventMap, type CCardElement, type CCardActionsElement, type CCardContentElement, type CCardTitleElement, type CCheckboxElement, type CCheckboxElementEventMap, type CCscLogoElement, type CDataTableElement, type CDataTableElementEventMap, type CDividerElement, type CIconElement, type CIconButtonElement, type CInputElement, type CLinkElement, type CListElement, type CListItemElement, type CListItemTitleElement, type CLoaderElement, type CLoginButtonElement, type CLoginButtonsElement, type CLoginCardElement, type CLoginCardActionsElement, type CLoginCardContentElement, type CLoginCardTitleElement, type CMainElement, type CMenuElement, type CMenuElementEventMap, type CMenuItemElement, type CMenuLabelElement, type CMessageElement, type CModalElement, type CModalElementEventMap, type CNavigationButtonElement, type COptionElement, type COptionValueElement, type COtpInputElement, type COtpInputElementEventMap, type CPageElement, type CPaginationElement, type CPaginationElementEventMap, type CPopoverElement, type CPopoverElementEventMap, type CProgressBarElement, type CProgressCircleElement, type CRadioElement, type CRadioElementEventMap, type CRadioGroupElement, type CRadioGroupElementEventMap, type CSelectElement, type CSelectElementEventMap, type CSideNavigationElement, type CSideNavigationElementEventMap, type CSideNavigationItemElement, type CSideNavigationItemElementEventMap, type CSideNavigationTitleElement, type CSliderElement, type CSliderElementEventMap, type CSpinnerElement, type CStatusElement, type CStepElement, type CStepsElement, type CSubNavigationItemElement, type CSwitchElement, type CSwitchElementEventMap, type CTabElement, type CTabElementEventMap, type CTabButtonsElement, type CTabButtonsElementEventMap, type CTabItemElement, type CTabItemElementEventMap, type CTabItemsElement, type CTableElement, type CTabsElement, type CTabsElementEventMap, type CTagElement, type CTagElementEventMap, type CTagsElement, type CTextFieldElement, type CTextFieldElementEventMap, type CToastElement, type CToastElementEventMap, type CToastsElement, type CToolbarElement, type CTooltipElement, type CTooltipElementEventMap } from '@cscfi/csc-ui';
7
7
  export declare const CAccordion: import("@lit/react").ReactWebComponent<CAccordionElement, {
8
8
  onChange: EventName<CAccordionElementEventMap["change"]>;
9
9
  onChangeValue: EventName<CAccordionElementEventMap["changeValue"]>;
@@ -13,7 +13,10 @@ export declare const CAccordion: import("@lit/react").ReactWebComponent<CAccordi
13
13
  export declare const CAccordionItem: import("@lit/react").ReactWebComponent<CAccordionItemElement, {
14
14
  onItemChange: EventName<CAccordionItemElementEventMap["item-change"]>;
15
15
  }>;
16
- export declare const CAlert: import("@lit/react").ReactWebComponent<CAlertElement, {}>;
16
+ /** A persistent, in-flow status message: a tinted box whose type carries a status family's colours through the icon, heading and accent edge, while the body copy stays neutral. */
17
+ export declare const CAlert: import("@lit/react").ReactWebComponent<CAlertElement, {
18
+ onDismiss: EventName<CAlertElementEventMap["dismiss"]>;
19
+ }>;
17
20
  /** A filterable value-selection component: a readonly value field that opens a popover panel with a search input above the matching options. */
18
21
  export declare const CAutocomplete: import("@lit/react").ReactWebComponent<CAutocompleteElement, {
19
22
  onChange: EventName<CAutocompleteElementEventMap["change"]>;
@@ -35,6 +38,7 @@ export declare const CCard: import("@lit/react").ReactWebComponent<CCardElement,
35
38
  export declare const CCardActions: import("@lit/react").ReactWebComponent<CCardActionsElement, {}>;
36
39
  export declare const CCardContent: import("@lit/react").ReactWebComponent<CCardContentElement, {}>;
37
40
  export declare const CCardTitle: import("@lit/react").ReactWebComponent<CCardTitleElement, {}>;
41
+ /** A form control for a single on/off choice: a native checkbox with a label, an optional hint, and validation messaging. */
38
42
  export declare const CCheckbox: import("@lit/react").ReactWebComponent<CCheckboxElement, {
39
43
  onChange: EventName<CCheckboxElementEventMap["change"]>;
40
44
  onChangeValue: EventName<CCheckboxElementEventMap["changeValue"]>;
@@ -98,8 +102,19 @@ export declare const CPagination: import("@lit/react").ReactWebComponent<CPagina
98
102
  onInput: EventName<CPaginationElementEventMap["input"]>;
99
103
  onUpdateValue: EventName<CPaginationElementEventMap["update:value"]>;
100
104
  }>;
105
+ /** A click-opened, non-modal surface anchored to its trigger, floating in the top layer; its content may be interactive. */
106
+ export declare const CPopover: import("@lit/react").ReactWebComponent<CPopoverElement, {
107
+ onChangeOpen: EventName<CPopoverElementEventMap["change:open"]>;
108
+ }>;
109
+ /** A horizontal progress bar that fills a track to a known completion percentage, with an optional details line showing the value and a label. */
101
110
  export declare const CProgressBar: import("@lit/react").ReactWebComponent<CProgressBarElement, {}>;
102
- export declare const CRadio: import("@lit/react").ReactWebComponent<CRadioElement, {}>;
111
+ /** A circular progress indicator that draws a known completion percentage as an arc around a track — the circular counterpart of `c-progress-bar`. */
112
+ export declare const CProgressCircle: import("@lit/react").ReactWebComponent<CProgressCircleElement, {}>;
113
+ /** A single radio option inside a `c-radio-group`: a native radio input whose default slot is its clickable, announced label. */
114
+ export declare const CRadio: import("@lit/react").ReactWebComponent<CRadioElement, {
115
+ onChange: EventName<CRadioElementEventMap["change"]>;
116
+ }>;
117
+ /** A radio group is a set of mutually exclusive choices where exactly one can be selected, authored as slotted `c-radio` children. Give the group a `label` so the choice it represents is named for every user, and a `hint` describing how to answer. */
103
118
  export declare const CRadioGroup: import("@lit/react").ReactWebComponent<CRadioGroupElement, {
104
119
  onChangeValue: EventName<CRadioGroupElementEventMap["changeValue"]>;
105
120
  onInput: EventName<CRadioGroupElementEventMap["input"]>;
@@ -122,11 +137,13 @@ export declare const CSlider: import("@lit/react").ReactWebComponent<CSliderElem
122
137
  onInput: EventName<CSliderElementEventMap["input"]>;
123
138
  onUpdateValue: EventName<CSliderElementEventMap["update:value"]>;
124
139
  }>;
140
+ /** A circular indeterminate activity indicator — pure motion with no value, for waits of unknown duration. */
125
141
  export declare const CSpinner: import("@lit/react").ReactWebComponent<CSpinnerElement, {}>;
126
142
  export declare const CStatus: import("@lit/react").ReactWebComponent<CStatusElement, {}>;
127
143
  export declare const CStep: import("@lit/react").ReactWebComponent<CStepElement, {}>;
128
144
  export declare const CSteps: import("@lit/react").ReactWebComponent<CStepsElement, {}>;
129
145
  export declare const CSubNavigationItem: import("@lit/react").ReactWebComponent<CSubNavigationItemElement, {}>;
146
+ /** A toggle for a binary setting that takes effect immediately: a native switch control with a label, an optional hint, and validation messaging. */
130
147
  export declare const CSwitch: import("@lit/react").ReactWebComponent<CSwitchElement, {
131
148
  onChange: EventName<CSwitchElementEventMap["change"]>;
132
149
  onChangeValue: EventName<CSwitchElementEventMap["changeValue"]>;
@@ -145,6 +162,7 @@ export declare const CTabItem: import("@lit/react").ReactWebComponent<CTabItemEl
145
162
  onContentChange: EventName<CTabItemElementEventMap["contentChange"]>;
146
163
  }>;
147
164
  export declare const CTabItems: import("@lit/react").ReactWebComponent<CTabItemsElement, {}>;
165
+ /** A styled wrapper for a table you author yourself: slot in a plain `<table>` and c-table gives it the CSC look plus an optional responsive card layout on narrow screens. The table stays in your own DOM — your stylesheets, your framework's rendering, and `::part()` selectors on components nested in cells (a `c-tag` status chip, a `c-pagination` footer) all keep working. */
148
166
  export declare const CTable: import("@lit/react").ReactWebComponent<CTableElement, {}>;
149
167
  export declare const CTabs: import("@lit/react").ReactWebComponent<CTabsElement, {
150
168
  onChangeValue: EventName<CTabsElementEventMap["changeValue"]>;
@@ -168,3 +186,7 @@ export declare const CToast: import("@lit/react").ReactWebComponent<CToastElemen
168
186
  /** Toasts are passive, transient notifications — operation results, background progress — stacked and managed by a single `c-toasts` container via its `addToast` / `removeToast` methods. */
169
187
  export declare const CToasts: import("@lit/react").ReactWebComponent<CToastsElement, {}>;
170
188
  export declare const CToolbar: import("@lit/react").ReactWebComponent<CToolbarElement, {}>;
189
+ /** A non-interactive text hint shown when its trigger is hovered or keyboard-focused, floating in the top layer on the inverted surface tier. */
190
+ export declare const CTooltip: import("@lit/react").ReactWebComponent<CTooltipElement, {
191
+ onChangeOpen: EventName<CTooltipElementEventMap["change:open"]>;
192
+ }>;
@@ -42,9 +42,13 @@ export const CAccordionItem = createComponent({
42
42
  react: React,
43
43
  tagName: 'c-accordion-item',
44
44
  });
45
+ /** A persistent, in-flow status message: a tinted box whose type carries a status family's colours through the icon, heading and accent edge, while the body copy stays neutral. */
45
46
  export const CAlert = createComponent({
46
47
  displayName: 'CAlert',
47
48
  elementClass: elementClass('c-alert'),
49
+ events: {
50
+ onDismiss: 'dismiss',
51
+ },
48
52
  react: React,
49
53
  tagName: 'c-alert',
50
54
  });
@@ -111,6 +115,7 @@ export const CCardTitle = createComponent({
111
115
  react: React,
112
116
  tagName: 'c-card-title',
113
117
  });
118
+ /** A form control for a single on/off choice: a native checkbox with a label, an optional hint, and validation messaging. */
114
119
  export const CCheckbox = createComponent({
115
120
  displayName: 'CCheckbox',
116
121
  elementClass: elementClass('c-checkbox'),
@@ -330,18 +335,41 @@ export const CPagination = createComponent({
330
335
  react: React,
331
336
  tagName: 'c-pagination',
332
337
  });
338
+ /** A click-opened, non-modal surface anchored to its trigger, floating in the top layer; its content may be interactive. */
339
+ export const CPopover = createComponent({
340
+ displayName: 'CPopover',
341
+ elementClass: elementClass('c-popover'),
342
+ events: {
343
+ onChangeOpen: 'change:open',
344
+ },
345
+ react: React,
346
+ tagName: 'c-popover',
347
+ });
348
+ /** A horizontal progress bar that fills a track to a known completion percentage, with an optional details line showing the value and a label. */
333
349
  export const CProgressBar = createComponent({
334
350
  displayName: 'CProgressBar',
335
351
  elementClass: elementClass('c-progress-bar'),
336
352
  react: React,
337
353
  tagName: 'c-progress-bar',
338
354
  });
355
+ /** A circular progress indicator that draws a known completion percentage as an arc around a track — the circular counterpart of `c-progress-bar`. */
356
+ export const CProgressCircle = createComponent({
357
+ displayName: 'CProgressCircle',
358
+ elementClass: elementClass('c-progress-circle'),
359
+ react: React,
360
+ tagName: 'c-progress-circle',
361
+ });
362
+ /** A single radio option inside a `c-radio-group`: a native radio input whose default slot is its clickable, announced label. */
339
363
  export const CRadio = createComponent({
340
364
  displayName: 'CRadio',
341
365
  elementClass: elementClass('c-radio'),
366
+ events: {
367
+ onChange: 'change',
368
+ },
342
369
  react: React,
343
370
  tagName: 'c-radio',
344
371
  });
372
+ /** A radio group is a set of mutually exclusive choices where exactly one can be selected, authored as slotted `c-radio` children. Give the group a `label` so the choice it represents is named for every user, and a `hint` describing how to answer. */
345
373
  export const CRadioGroup = createComponent({
346
374
  displayName: 'CRadioGroup',
347
375
  elementClass: elementClass('c-radio-group'),
@@ -399,6 +427,7 @@ export const CSlider = createComponent({
399
427
  react: React,
400
428
  tagName: 'c-slider',
401
429
  });
430
+ /** A circular indeterminate activity indicator — pure motion with no value, for waits of unknown duration. */
402
431
  export const CSpinner = createComponent({
403
432
  displayName: 'CSpinner',
404
433
  elementClass: elementClass('c-spinner'),
@@ -429,6 +458,7 @@ export const CSubNavigationItem = createComponent({
429
458
  react: React,
430
459
  tagName: 'c-sub-navigation-item',
431
460
  });
461
+ /** A toggle for a binary setting that takes effect immediately: a native switch control with a label, an optional hint, and validation messaging. */
432
462
  export const CSwitch = createComponent({
433
463
  displayName: 'CSwitch',
434
464
  elementClass: elementClass('c-switch'),
@@ -476,6 +506,7 @@ export const CTabItems = createComponent({
476
506
  react: React,
477
507
  tagName: 'c-tab-items',
478
508
  });
509
+ /** A styled wrapper for a table you author yourself: slot in a plain `<table>` and c-table gives it the CSC look plus an optional responsive card layout on narrow screens. The table stays in your own DOM — your stylesheets, your framework's rendering, and `::part()` selectors on components nested in cells (a `c-tag` status chip, a `c-pagination` footer) all keep working. */
479
510
  export const CTable = createComponent({
480
511
  displayName: 'CTable',
481
512
  elementClass: elementClass('c-table'),
@@ -543,3 +574,13 @@ export const CToolbar = createComponent({
543
574
  react: React,
544
575
  tagName: 'c-toolbar',
545
576
  });
577
+ /** A non-interactive text hint shown when its trigger is hovered or keyboard-focused, floating in the top layer on the inverted surface tier. */
578
+ export const CTooltip = createComponent({
579
+ displayName: 'CTooltip',
580
+ elementClass: elementClass('c-tooltip'),
581
+ events: {
582
+ onChangeOpen: 'change:open',
583
+ },
584
+ react: React,
585
+ tagName: 'c-tooltip',
586
+ });
package/dist/index.d.ts CHANGED
@@ -6,6 +6,8 @@
6
6
  * types come from `@cscfi/csc-ui` — import any option/item types you
7
7
  * need (e.g. `CSelectItem`) from there.
8
8
  */
9
- export * from './components.js';
10
- export { applyTheme, resetTheme, themeToCss } from '@cscfi/csc-ui';
11
- export type { Family, ThemeSeeds } from '@cscfi/csc-ui';
9
+ export * from "./components.js";
10
+ export { DEFAULT_SEEDS, FAMILIES, applyTheme, resetTheme, themeToCss, } from "@cscfi/csc-ui";
11
+ export type { Family, ThemeSeeds } from "@cscfi/csc-ui";
12
+ export { chartAnatomy, chartAnatomyHex, chartSlots, chartSlotsHex, themeMode, } from "@cscfi/csc-ui";
13
+ export type { ChartAnatomy, ChartSlots, ThemeMode } from "@cscfi/csc-ui";
package/dist/index.js CHANGED
@@ -6,5 +6,6 @@
6
6
  * types come from `@cscfi/csc-ui` — import any option/item types you
7
7
  * need (e.g. `CSelectItem`) from there.
8
8
  */
9
- export * from './components.js';
10
- export { applyTheme, resetTheme, themeToCss } from '@cscfi/csc-ui';
9
+ export * from "./components.js";
10
+ export { DEFAULT_SEEDS, FAMILIES, applyTheme, resetTheme, themeToCss, } from "@cscfi/csc-ui";
11
+ export { chartAnatomy, chartAnatomyHex, chartSlots, chartSlotsHex, themeMode, } from "@cscfi/csc-ui";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cscfi/csc-ui-react",
3
- "version": "4.0.0-alpha.1",
3
+ "version": "4.0.0-alpha.10",
4
4
  "description": "React components for the @cscfi/csc-ui custom elements, generated from the Custom Elements Manifest.",
5
5
  "author": "My CSC Team <suiteamsui@gmail.com>",
6
6
  "type": "module",
@@ -21,13 +21,13 @@
21
21
  },
22
22
  "peerDependencies": {
23
23
  "react": ">=18",
24
- "@cscfi/csc-ui": "^4.0.0-alpha.1"
24
+ "@cscfi/csc-ui": "^4.0.0-alpha.10"
25
25
  },
26
26
  "devDependencies": {
27
27
  "@types/react": "^19.1.8",
28
28
  "react": "^19.1.0",
29
29
  "typescript": "^6.0.3",
30
- "@cscfi/csc-ui": "4.0.0-alpha.1"
30
+ "@cscfi/csc-ui": "4.0.0-alpha.10"
31
31
  },
32
32
  "license": "MIT",
33
33
  "repository": "CSCfi/ui",