@krollins/blueprint 0.1.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/LICENSE +21 -0
- package/README.md +407 -0
- package/dist/components/accordion/accordion.d.ts +113 -0
- package/dist/components/accordion/accordion.d.ts.map +1 -0
- package/dist/components/accordion/accordion.style.d.ts +2 -0
- package/dist/components/accordion/accordion.style.d.ts.map +1 -0
- package/dist/components/alert/alert.d.ts +37 -0
- package/dist/components/alert/alert.d.ts.map +1 -0
- package/dist/components/alert/alert.style.d.ts +2 -0
- package/dist/components/alert/alert.style.d.ts.map +1 -0
- package/dist/components/avatar/avatar.d.ts +75 -0
- package/dist/components/avatar/avatar.d.ts.map +1 -0
- package/dist/components/avatar/avatar.style.d.ts +2 -0
- package/dist/components/avatar/avatar.style.d.ts.map +1 -0
- package/dist/components/badge/badge.d.ts +46 -0
- package/dist/components/badge/badge.d.ts.map +1 -0
- package/dist/components/badge/badge.style.d.ts +2 -0
- package/dist/components/badge/badge.style.d.ts.map +1 -0
- package/dist/components/breadcrumb/breadcrumb.d.ts +110 -0
- package/dist/components/breadcrumb/breadcrumb.d.ts.map +1 -0
- package/dist/components/breadcrumb/breadcrumb.style.d.ts +2 -0
- package/dist/components/breadcrumb/breadcrumb.style.d.ts.map +1 -0
- package/dist/components/button/button.d.ts +19 -0
- package/dist/components/button/button.d.ts.map +1 -0
- package/dist/components/button/button.style.d.ts +2 -0
- package/dist/components/button/button.style.d.ts.map +1 -0
- package/dist/components/card/card.d.ts +62 -0
- package/dist/components/card/card.d.ts.map +1 -0
- package/dist/components/card/card.style.d.ts +2 -0
- package/dist/components/card/card.style.d.ts.map +1 -0
- package/dist/components/checkbox/checkbox.d.ts +89 -0
- package/dist/components/checkbox/checkbox.d.ts.map +1 -0
- package/dist/components/checkbox/checkbox.style.d.ts +2 -0
- package/dist/components/checkbox/checkbox.style.d.ts.map +1 -0
- package/dist/components/color-picker/color-picker.d.ts +366 -0
- package/dist/components/color-picker/color-picker.d.ts.map +1 -0
- package/dist/components/color-picker/color-picker.style.d.ts +14 -0
- package/dist/components/color-picker/color-picker.style.d.ts.map +1 -0
- package/dist/components/color-picker/color-picker.utils.d.ts +100 -0
- package/dist/components/color-picker/color-picker.utils.d.ts.map +1 -0
- package/dist/components/combobox/combobox.d.ts +74 -0
- package/dist/components/combobox/combobox.d.ts.map +1 -0
- package/dist/components/combobox/combobox.style.d.ts +2 -0
- package/dist/components/combobox/combobox.style.d.ts.map +1 -0
- package/dist/components/date-picker/date-picker.d.ts +65 -0
- package/dist/components/date-picker/date-picker.d.ts.map +1 -0
- package/dist/components/date-picker/date-picker.style.d.ts +2 -0
- package/dist/components/date-picker/date-picker.style.d.ts.map +1 -0
- package/dist/components/divider/divider.d.ts +54 -0
- package/dist/components/divider/divider.d.ts.map +1 -0
- package/dist/components/divider/divider.style.d.ts +2 -0
- package/dist/components/divider/divider.style.d.ts.map +1 -0
- package/dist/components/drawer/drawer.d.ts +113 -0
- package/dist/components/drawer/drawer.d.ts.map +1 -0
- package/dist/components/drawer/drawer.style.d.ts +2 -0
- package/dist/components/drawer/drawer.style.d.ts.map +1 -0
- package/dist/components/dropdown/dropdown.d.ts +80 -0
- package/dist/components/dropdown/dropdown.d.ts.map +1 -0
- package/dist/components/dropdown/dropdown.style.d.ts +2 -0
- package/dist/components/dropdown/dropdown.style.d.ts.map +1 -0
- package/dist/components/file-upload/file-upload.d.ts +116 -0
- package/dist/components/file-upload/file-upload.d.ts.map +1 -0
- package/dist/components/file-upload/file-upload.style.d.ts +2 -0
- package/dist/components/file-upload/file-upload.style.d.ts.map +1 -0
- package/dist/components/heading/heading.d.ts +46 -0
- package/dist/components/heading/heading.d.ts.map +1 -0
- package/dist/components/heading/heading.style.d.ts +2 -0
- package/dist/components/heading/heading.style.d.ts.map +1 -0
- package/dist/components/icon/icon.d.ts +57 -0
- package/dist/components/icon/icon.d.ts.map +1 -0
- package/dist/components/icon/icon.style.d.ts +2 -0
- package/dist/components/icon/icon.style.d.ts.map +1 -0
- package/dist/components/icon/icons/registry.generated.d.ts +25 -0
- package/dist/components/icon/icons/registry.generated.d.ts.map +1 -0
- package/dist/components/index.d.ts +45 -0
- package/dist/components/index.d.ts.map +1 -0
- package/dist/components/input/input.d.ts +56 -0
- package/dist/components/input/input.d.ts.map +1 -0
- package/dist/components/input/input.style.d.ts +2 -0
- package/dist/components/input/input.style.d.ts.map +1 -0
- package/dist/components/link/link.d.ts +62 -0
- package/dist/components/link/link.d.ts.map +1 -0
- package/dist/components/link/link.style.d.ts +2 -0
- package/dist/components/link/link.style.d.ts.map +1 -0
- package/dist/components/menu/menu.d.ts +86 -0
- package/dist/components/menu/menu.d.ts.map +1 -0
- package/dist/components/menu/menu.style.d.ts +2 -0
- package/dist/components/menu/menu.style.d.ts.map +1 -0
- package/dist/components/modal/modal.d.ts +40 -0
- package/dist/components/modal/modal.d.ts.map +1 -0
- package/dist/components/modal/modal.style.d.ts +2 -0
- package/dist/components/modal/modal.style.d.ts.map +1 -0
- package/dist/components/multi-select/multi-select.d.ts +69 -0
- package/dist/components/multi-select/multi-select.d.ts.map +1 -0
- package/dist/components/multi-select/multi-select.style.d.ts +2 -0
- package/dist/components/multi-select/multi-select.style.d.ts.map +1 -0
- package/dist/components/notification/notification.d.ts +102 -0
- package/dist/components/notification/notification.d.ts.map +1 -0
- package/dist/components/notification/notification.style.d.ts +2 -0
- package/dist/components/notification/notification.style.d.ts.map +1 -0
- package/dist/components/number-input/number-input.d.ts +139 -0
- package/dist/components/number-input/number-input.d.ts.map +1 -0
- package/dist/components/number-input/number-input.style.d.ts +2 -0
- package/dist/components/number-input/number-input.style.d.ts.map +1 -0
- package/dist/components/pagination/pagination.d.ts +49 -0
- package/dist/components/pagination/pagination.d.ts.map +1 -0
- package/dist/components/pagination/pagination.style.d.ts +2 -0
- package/dist/components/pagination/pagination.style.d.ts.map +1 -0
- package/dist/components/popover/popover.d.ts +153 -0
- package/dist/components/popover/popover.d.ts.map +1 -0
- package/dist/components/popover/popover.style.d.ts +2 -0
- package/dist/components/popover/popover.style.d.ts.map +1 -0
- package/dist/components/progress/progress.d.ts +50 -0
- package/dist/components/progress/progress.d.ts.map +1 -0
- package/dist/components/progress/progress.style.d.ts +2 -0
- package/dist/components/progress/progress.style.d.ts.map +1 -0
- package/dist/components/radio/radio.d.ts +95 -0
- package/dist/components/radio/radio.d.ts.map +1 -0
- package/dist/components/radio/radio.style.d.ts +2 -0
- package/dist/components/radio/radio.style.d.ts.map +1 -0
- package/dist/components/select/select.d.ts +49 -0
- package/dist/components/select/select.d.ts.map +1 -0
- package/dist/components/select/select.style.d.ts +2 -0
- package/dist/components/select/select.style.d.ts.map +1 -0
- package/dist/components/skeleton/skeleton.d.ts +50 -0
- package/dist/components/skeleton/skeleton.d.ts.map +1 -0
- package/dist/components/skeleton/skeleton.style.d.ts +2 -0
- package/dist/components/skeleton/skeleton.style.d.ts.map +1 -0
- package/dist/components/slider/slider.d.ts +115 -0
- package/dist/components/slider/slider.d.ts.map +1 -0
- package/dist/components/slider/slider.style.d.ts +2 -0
- package/dist/components/slider/slider.style.d.ts.map +1 -0
- package/dist/components/spinner/spinner.d.ts +36 -0
- package/dist/components/spinner/spinner.d.ts.map +1 -0
- package/dist/components/spinner/spinner.style.d.ts +2 -0
- package/dist/components/spinner/spinner.style.d.ts.map +1 -0
- package/dist/components/stepper/stepper.d.ts +228 -0
- package/dist/components/stepper/stepper.d.ts.map +1 -0
- package/dist/components/stepper/stepper.style.d.ts +2 -0
- package/dist/components/stepper/stepper.style.d.ts.map +1 -0
- package/dist/components/switch/switch.d.ts +90 -0
- package/dist/components/switch/switch.d.ts.map +1 -0
- package/dist/components/switch/switch.style.d.ts +2 -0
- package/dist/components/switch/switch.style.d.ts.map +1 -0
- package/dist/components/table/table.d.ts +176 -0
- package/dist/components/table/table.d.ts.map +1 -0
- package/dist/components/table/table.style.d.ts +2 -0
- package/dist/components/table/table.style.d.ts.map +1 -0
- package/dist/components/tabs/tabs.d.ts +124 -0
- package/dist/components/tabs/tabs.d.ts.map +1 -0
- package/dist/components/tabs/tabs.style.d.ts +2 -0
- package/dist/components/tabs/tabs.style.d.ts.map +1 -0
- package/dist/components/tag/tag.d.ts +64 -0
- package/dist/components/tag/tag.d.ts.map +1 -0
- package/dist/components/tag/tag.style.d.ts +2 -0
- package/dist/components/tag/tag.style.d.ts.map +1 -0
- package/dist/components/text/text.d.ts +86 -0
- package/dist/components/text/text.d.ts.map +1 -0
- package/dist/components/text/text.style.d.ts +2 -0
- package/dist/components/text/text.style.d.ts.map +1 -0
- package/dist/components/textarea/textarea.d.ts +94 -0
- package/dist/components/textarea/textarea.d.ts.map +1 -0
- package/dist/components/textarea/textarea.style.d.ts +2 -0
- package/dist/components/textarea/textarea.style.d.ts.map +1 -0
- package/dist/components/time-picker/time-picker.d.ts +51 -0
- package/dist/components/time-picker/time-picker.d.ts.map +1 -0
- package/dist/components/time-picker/time-picker.style.d.ts +2 -0
- package/dist/components/time-picker/time-picker.style.d.ts.map +1 -0
- package/dist/components/tooltip/tooltip.d.ts +52 -0
- package/dist/components/tooltip/tooltip.d.ts.map +1 -0
- package/dist/components/tooltip/tooltip.style.d.ts +2 -0
- package/dist/components/tooltip/tooltip.style.d.ts.map +1 -0
- package/dist/components/tree/tree.d.ts +188 -0
- package/dist/components/tree/tree.d.ts.map +1 -0
- package/dist/components/tree/tree.style.d.ts +2 -0
- package/dist/components/tree/tree.style.d.ts.map +1 -0
- package/dist/index.css +1 -0
- package/dist/index.d.ts +5 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +17802 -0
- package/dist/index.js.map +1 -0
- package/dist/utilities/boolean-converter.d.ts +23 -0
- package/dist/utilities/boolean-converter.d.ts.map +1 -0
- package/dist/utilities/debounce.d.ts +12 -0
- package/dist/utilities/debounce.d.ts.map +1 -0
- package/dist/utilities/index.d.ts +5 -0
- package/dist/utilities/index.d.ts.map +1 -0
- package/dist/utilities/memoize.d.ts +7 -0
- package/dist/utilities/memoize.d.ts.map +1 -0
- package/dist/utilities/throttle.d.ts +12 -0
- package/dist/utilities/throttle.d.ts.map +1 -0
- package/package.json +93 -0
|
@@ -0,0 +1,176 @@
|
|
|
1
|
+
import { LitElement, TemplateResult, PropertyValues } from 'lit';
|
|
2
|
+
import '../icon/icon.js';
|
|
3
|
+
export type TableVariant = 'default' | 'striped' | 'bordered';
|
|
4
|
+
export type TableSize = 'sm' | 'md' | 'lg';
|
|
5
|
+
export type TableSortDirection = 'asc' | 'desc' | 'none';
|
|
6
|
+
/**
|
|
7
|
+
* Column definition for the table
|
|
8
|
+
*/
|
|
9
|
+
export interface TableColumn {
|
|
10
|
+
/** Unique key for the column (matches data property) */
|
|
11
|
+
key: string;
|
|
12
|
+
/** Header label for the column */
|
|
13
|
+
label: string;
|
|
14
|
+
/** Whether this column is sortable */
|
|
15
|
+
sortable?: boolean;
|
|
16
|
+
/** Text alignment */
|
|
17
|
+
align?: 'left' | 'center' | 'right';
|
|
18
|
+
/** Fixed width for the column */
|
|
19
|
+
width?: string;
|
|
20
|
+
/** Custom render function for cell content */
|
|
21
|
+
render?: (value: unknown, row: TableRow) => TemplateResult | string;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Row data for the table
|
|
25
|
+
*/
|
|
26
|
+
export interface TableRow {
|
|
27
|
+
/** Unique identifier for the row */
|
|
28
|
+
id: string | number;
|
|
29
|
+
/** Row data keyed by column key */
|
|
30
|
+
[key: string]: unknown;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Sort state for the table
|
|
34
|
+
*/
|
|
35
|
+
export interface TableSortState {
|
|
36
|
+
/** Column key being sorted */
|
|
37
|
+
column: string;
|
|
38
|
+
/** Sort direction */
|
|
39
|
+
direction: TableSortDirection;
|
|
40
|
+
}
|
|
41
|
+
/**
|
|
42
|
+
* A data table component for displaying tabular data with sorting and selection.
|
|
43
|
+
*
|
|
44
|
+
* @element bp-table
|
|
45
|
+
*
|
|
46
|
+
* @property {TableColumn[]} columns - Array of column definitions
|
|
47
|
+
* @property {TableRow[]} rows - Array of row data objects
|
|
48
|
+
* @property {TableVariant} variant - Visual style variant
|
|
49
|
+
* @property {TableSize} size - Size of the table cells
|
|
50
|
+
* @property {boolean} selectable - Whether rows can be selected
|
|
51
|
+
* @property {boolean} multiSelect - Whether multiple rows can be selected
|
|
52
|
+
* @property {(string|number)[]} selectedRows - Array of selected row IDs
|
|
53
|
+
* @property {TableSortState} sortState - Current sort state
|
|
54
|
+
* @property {boolean} stickyHeader - Whether the header sticks on scroll
|
|
55
|
+
* @property {boolean} hoverable - Whether rows highlight on hover
|
|
56
|
+
* @property {boolean} loading - Whether the table is in loading state
|
|
57
|
+
*
|
|
58
|
+
* @fires bp-sort - Fired when a sortable column header is clicked
|
|
59
|
+
* @fires bp-select - Fired when row selection changes
|
|
60
|
+
* @fires bp-row-click - Fired when a row is clicked
|
|
61
|
+
*
|
|
62
|
+
* @slot empty - Content to show when table has no data
|
|
63
|
+
* @slot loading - Content to show when table is loading
|
|
64
|
+
*
|
|
65
|
+
* @csspart table - The table element
|
|
66
|
+
* @csspart thead - The table header section
|
|
67
|
+
* @csspart tbody - The table body section
|
|
68
|
+
* @csspart header-row - A header row
|
|
69
|
+
* @csspart header-cell - A header cell
|
|
70
|
+
* @csspart row - A data row
|
|
71
|
+
* @csspart cell - A data cell
|
|
72
|
+
* @csspart checkbox - Selection checkbox
|
|
73
|
+
* @csspart sort-icon - Sort direction icon
|
|
74
|
+
* @csspart empty-state - Empty state container
|
|
75
|
+
*/
|
|
76
|
+
export declare class BpTable extends LitElement {
|
|
77
|
+
/** Array of column definitions */
|
|
78
|
+
columns: TableColumn[];
|
|
79
|
+
/** Array of row data objects */
|
|
80
|
+
rows: TableRow[];
|
|
81
|
+
/** Visual style variant */
|
|
82
|
+
variant: TableVariant;
|
|
83
|
+
/** Size of the table cells */
|
|
84
|
+
size: TableSize;
|
|
85
|
+
/** Whether rows can be selected */
|
|
86
|
+
selectable: boolean;
|
|
87
|
+
/** Whether multiple rows can be selected */
|
|
88
|
+
multiSelect: boolean;
|
|
89
|
+
/** Array of selected row IDs */
|
|
90
|
+
selectedRows: (string | number)[];
|
|
91
|
+
/** Current sort state */
|
|
92
|
+
sortState: TableSortState | null;
|
|
93
|
+
/** Whether the header sticks on scroll */
|
|
94
|
+
stickyHeader: boolean;
|
|
95
|
+
/** Whether rows highlight on hover */
|
|
96
|
+
hoverable: boolean;
|
|
97
|
+
/** Whether the table is in loading state */
|
|
98
|
+
loading: boolean;
|
|
99
|
+
private allSelected;
|
|
100
|
+
/**
|
|
101
|
+
* Properties that only affect visual styling, not rendered structure.
|
|
102
|
+
* Changes to only these properties can skip a full re-render.
|
|
103
|
+
*/
|
|
104
|
+
private static readonly VISUAL_ONLY_PROPS;
|
|
105
|
+
static styles: import("lit").CSSResult[];
|
|
106
|
+
constructor();
|
|
107
|
+
protected shouldUpdate(changedProperties: PropertyValues): boolean;
|
|
108
|
+
updated(changedProperties: Map<string, unknown>): void;
|
|
109
|
+
/**
|
|
110
|
+
* Memoized sorted rows computation.
|
|
111
|
+
* Only recomputes when rows or sortState references change.
|
|
112
|
+
*/
|
|
113
|
+
private computeSortedRows;
|
|
114
|
+
/**
|
|
115
|
+
* Get sorted rows based on current sort state (memoized).
|
|
116
|
+
*/
|
|
117
|
+
private get sortedRows();
|
|
118
|
+
/**
|
|
119
|
+
* Handles click on sortable column header.
|
|
120
|
+
* Cycles through sort directions: asc → desc → none.
|
|
121
|
+
* Manages focus on header after sort completes.
|
|
122
|
+
*/
|
|
123
|
+
private handleHeaderClick;
|
|
124
|
+
/**
|
|
125
|
+
* Handles click events on table rows.
|
|
126
|
+
* Dispatches bp-row-click event and toggles selection if selectable.
|
|
127
|
+
*/
|
|
128
|
+
private handleRowClick;
|
|
129
|
+
/**
|
|
130
|
+
* Handles keyboard events on table rows.
|
|
131
|
+
* Triggers selection on Enter or Space key press when selectable.
|
|
132
|
+
*/
|
|
133
|
+
private handleRowKeyDown;
|
|
134
|
+
/**
|
|
135
|
+
* Toggles selection state for a row.
|
|
136
|
+
* Respects multiSelect setting for single vs multiple selection.
|
|
137
|
+
*/
|
|
138
|
+
private toggleRowSelection;
|
|
139
|
+
/**
|
|
140
|
+
* Handles select all checkbox toggle.
|
|
141
|
+
* Selects or deselects all rows based on current state.
|
|
142
|
+
*/
|
|
143
|
+
private handleSelectAll;
|
|
144
|
+
/**
|
|
145
|
+
* Handles checkbox click events.
|
|
146
|
+
* Stops propagation only on the checkbox itself to prevent row click.
|
|
147
|
+
*/
|
|
148
|
+
private handleCheckboxClick;
|
|
149
|
+
/** Select all rows */
|
|
150
|
+
selectAll(): void;
|
|
151
|
+
/** Deselect all rows */
|
|
152
|
+
deselectAll(): void;
|
|
153
|
+
/** Clear sort state */
|
|
154
|
+
clearSort(): void;
|
|
155
|
+
/**
|
|
156
|
+
* Renders the sort icon for sortable columns.
|
|
157
|
+
* Shows chevron-up for ascending, chevron-down for descending, unsorted icon otherwise.
|
|
158
|
+
*/
|
|
159
|
+
private renderSortIcon;
|
|
160
|
+
/**
|
|
161
|
+
* Renders the table header with column labels and sort icons.
|
|
162
|
+
*/
|
|
163
|
+
private renderHeader;
|
|
164
|
+
/**
|
|
165
|
+
* Renders the table body with rows and cells.
|
|
166
|
+
* Handles loading and empty states.
|
|
167
|
+
*/
|
|
168
|
+
private renderBody;
|
|
169
|
+
render(): TemplateResult<1>;
|
|
170
|
+
}
|
|
171
|
+
declare global {
|
|
172
|
+
interface HTMLElementTagNameMap {
|
|
173
|
+
'bp-table': BpTable;
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
//# sourceMappingURL=table.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"table.d.ts","sourceRoot":"","sources":["../../../source/components/table/table.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAiB,cAAc,EAAE,cAAc,EAAE,MAAM,KAAK,CAAC;AAQhF,OAAO,iBAAiB,CAAC;AAE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AAC;KACrB;CACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"table.style.d.ts","sourceRoot":"","sources":["../../../source/components/table/table.style.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,WAAW,yBAkQvB,CAAC"}
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
import { LitElement } from 'lit';
|
|
2
|
+
import type { IconName } from '../icon/icons/registry.generated.js';
|
|
3
|
+
export type TabsSize = 'sm' | 'md' | 'lg';
|
|
4
|
+
export type TabsVariant = 'default' | 'pills' | 'underline';
|
|
5
|
+
export type TabsPlacement = 'top' | 'bottom' | 'start' | 'end';
|
|
6
|
+
/**
|
|
7
|
+
* Tab item interface for programmatic tab configuration
|
|
8
|
+
*/
|
|
9
|
+
export interface TabItem {
|
|
10
|
+
/** Unique identifier for the tab */
|
|
11
|
+
id: string;
|
|
12
|
+
/** Display label for the tab */
|
|
13
|
+
label: string;
|
|
14
|
+
/** Whether the tab is disabled */
|
|
15
|
+
disabled?: boolean;
|
|
16
|
+
/** Icon name to display before the label */
|
|
17
|
+
icon?: IconName;
|
|
18
|
+
/** Whether this tab can be closed */
|
|
19
|
+
closable?: boolean;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* A tabs component for organizing content into tabbed sections.
|
|
23
|
+
*
|
|
24
|
+
* @element bp-tabs
|
|
25
|
+
*
|
|
26
|
+
* @property {string} value - The ID of the currently selected tab
|
|
27
|
+
* @property {TabItem[]} tabs - Array of tab items (alternative to slotted tabs)
|
|
28
|
+
* @property {TabsSize} size - The size of the tabs
|
|
29
|
+
* @property {TabsVariant} variant - The visual style of the tabs
|
|
30
|
+
* @property {TabsPlacement} placement - Position of the tab list relative to panels
|
|
31
|
+
* @property {boolean} disabled - Whether all tabs are disabled
|
|
32
|
+
* @property {boolean} manual - Whether activation requires pressing Enter/Space (vs automatic on arrow)
|
|
33
|
+
*
|
|
34
|
+
* @slot - Default slot for bp-tab-panel elements
|
|
35
|
+
* @slot tab - Slot for custom tab buttons (use with data-tab-id attribute)
|
|
36
|
+
*
|
|
37
|
+
* @fires bp-tab-change - Fired when the selected tab changes
|
|
38
|
+
* @fires bp-tab-close - Fired when a closable tab's close button is clicked
|
|
39
|
+
*
|
|
40
|
+
* @csspart tabs - The main container
|
|
41
|
+
* @csspart tablist - The tab button list container
|
|
42
|
+
* @csspart tab - Individual tab button
|
|
43
|
+
* @csspart tab-active - The currently active tab
|
|
44
|
+
* @csspart tab-disabled - A disabled tab
|
|
45
|
+
* @csspart panels - The panel container
|
|
46
|
+
* @csspart panel - Individual panel wrapper
|
|
47
|
+
*/
|
|
48
|
+
export declare class BpTabs extends LitElement {
|
|
49
|
+
/**
|
|
50
|
+
* The ID of the currently selected tab
|
|
51
|
+
*/
|
|
52
|
+
value: string;
|
|
53
|
+
/**
|
|
54
|
+
* Array of tab items for programmatic tab configuration
|
|
55
|
+
*/
|
|
56
|
+
tabs: TabItem[];
|
|
57
|
+
/**
|
|
58
|
+
* The size of the tabs
|
|
59
|
+
*/
|
|
60
|
+
size: TabsSize;
|
|
61
|
+
/**
|
|
62
|
+
* The visual style of the tabs
|
|
63
|
+
*/
|
|
64
|
+
variant: TabsVariant;
|
|
65
|
+
/**
|
|
66
|
+
* Position of the tab list relative to panels
|
|
67
|
+
*/
|
|
68
|
+
placement: TabsPlacement;
|
|
69
|
+
/**
|
|
70
|
+
* Whether all tabs are disabled
|
|
71
|
+
*/
|
|
72
|
+
disabled: boolean;
|
|
73
|
+
/**
|
|
74
|
+
* Whether activation requires pressing Enter/Space (manual) vs automatic on arrow navigation
|
|
75
|
+
*/
|
|
76
|
+
manual: boolean;
|
|
77
|
+
private focusedTabId;
|
|
78
|
+
private panelElements;
|
|
79
|
+
static styles: import("lit").CSSResult[];
|
|
80
|
+
constructor();
|
|
81
|
+
connectedCallback(): void;
|
|
82
|
+
updated(changedProperties: Map<string, unknown>): void;
|
|
83
|
+
private handleSlotChange;
|
|
84
|
+
private getPanels;
|
|
85
|
+
private getEnabledTabs;
|
|
86
|
+
private updatePanelVisibility;
|
|
87
|
+
private handleTabClick;
|
|
88
|
+
private handleTabKeyDown;
|
|
89
|
+
private focusTab;
|
|
90
|
+
private selectTab;
|
|
91
|
+
private handleTabClose;
|
|
92
|
+
private handleTabFocus;
|
|
93
|
+
private handleTabBlur;
|
|
94
|
+
private renderTab;
|
|
95
|
+
render(): import("lit-html").TemplateResult<1>;
|
|
96
|
+
}
|
|
97
|
+
/**
|
|
98
|
+
* A tab panel component for use with bp-tabs.
|
|
99
|
+
*
|
|
100
|
+
* @element bp-tab-panel
|
|
101
|
+
*
|
|
102
|
+
* @property {string} tabId - The ID that links this panel to its tab
|
|
103
|
+
*
|
|
104
|
+
* @slot - Content of the panel
|
|
105
|
+
*
|
|
106
|
+
* @csspart panel - The panel container
|
|
107
|
+
*/
|
|
108
|
+
export declare class BpTabPanel extends LitElement {
|
|
109
|
+
/**
|
|
110
|
+
* The ID that links this panel to its tab
|
|
111
|
+
*/
|
|
112
|
+
tabId: string;
|
|
113
|
+
constructor();
|
|
114
|
+
connectedCallback(): void;
|
|
115
|
+
updated(changedProperties: Map<string, unknown>): void;
|
|
116
|
+
render(): import("lit-html").TemplateResult<1>;
|
|
117
|
+
}
|
|
118
|
+
declare global {
|
|
119
|
+
interface HTMLElementTagNameMap {
|
|
120
|
+
'bp-tabs': BpTabs;
|
|
121
|
+
'bp-tab-panel': BpTabPanel;
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
//# sourceMappingURL=tabs.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tabs.d.ts","sourceRoot":"","sources":["../../../source/components/tabs/tabs.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAiB,MAAM,KAAK,CAAC;AAUhD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,qCAAqC,CAAC;AAEpE,MAAM,MAAM,QAAQ,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CA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,QAAQ;IAOhB,OAAO,CAAC,SAAS;IAmBjB,OAAO,CAAC,cAAc,CAoBpB;IAEF,OAAO,CAAC,cAAc,CAEpB;IAEF,OAAO,CAAC,aAAa,CAEnB;IAEF,OAAO,CAAC,SAAS;IAyDjB,MAAM;CA8BP;AAED;;;;;;;;;;GAUG;AACH,qBACa,UAAW,SAAQ,UAAU;IACxC;;OAEG;IAEK,KAAK,EAAE,MAAM,CAAC;;IAOtB,iBAAiB,IAAI,IAAI;IAMzB,OAAO,CAAC,iBAAiB,EAAE,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,IAAI;IAStD,MAAM;CAGP;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,SAAS,EAAE,MAAM,CAAC;QAClB,cAAc,EAAE,UAAU,CAAC;KAC5B;CACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tabs.style.d.ts","sourceRoot":"","sources":["../../../source/components/tabs/tabs.style.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,UAAU,yBAgTtB,CAAC"}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { LitElement } from 'lit';
|
|
2
|
+
import '../icon/icon.js';
|
|
3
|
+
/**
|
|
4
|
+
* Tag component for displaying removable labels, chips, or category markers.
|
|
5
|
+
*
|
|
6
|
+
* @element bp-tag
|
|
7
|
+
*
|
|
8
|
+
* @slot - Default slot for tag content (text)
|
|
9
|
+
*
|
|
10
|
+
* @csspart tag - The tag container element
|
|
11
|
+
* @csspart close-button - The close/remove button element
|
|
12
|
+
*
|
|
13
|
+
* @fires bp-remove - Fired when the tag is removed (cancelable)
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* ```html
|
|
17
|
+
* <bp-tag>Design</bp-tag>
|
|
18
|
+
* <bp-tag variant="outlined" removable>TypeScript</bp-tag>
|
|
19
|
+
* <bp-tag variant="success" size="sm">Active</bp-tag>
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
export declare class BpTag extends LitElement {
|
|
23
|
+
/**
|
|
24
|
+
* Visual variant of the tag
|
|
25
|
+
* @type {'solid' | 'outlined'}
|
|
26
|
+
* @default 'solid'
|
|
27
|
+
*/
|
|
28
|
+
variant: 'solid' | 'outlined';
|
|
29
|
+
/**
|
|
30
|
+
* Size of the tag
|
|
31
|
+
* @type {'sm' | 'md' | 'lg'}
|
|
32
|
+
* @default 'md'
|
|
33
|
+
*/
|
|
34
|
+
size: 'sm' | 'md' | 'lg';
|
|
35
|
+
/**
|
|
36
|
+
* Color scheme of the tag
|
|
37
|
+
* @type {'primary' | 'success' | 'error' | 'warning' | 'info' | 'neutral'}
|
|
38
|
+
* @default 'neutral'
|
|
39
|
+
*/
|
|
40
|
+
color: 'primary' | 'success' | 'error' | 'warning' | 'info' | 'neutral';
|
|
41
|
+
/**
|
|
42
|
+
* Whether the tag can be removed
|
|
43
|
+
* @type {boolean}
|
|
44
|
+
* @default false
|
|
45
|
+
*/
|
|
46
|
+
removable: boolean;
|
|
47
|
+
/**
|
|
48
|
+
* Whether the tag is disabled
|
|
49
|
+
* @type {boolean}
|
|
50
|
+
* @default false
|
|
51
|
+
*/
|
|
52
|
+
disabled: boolean;
|
|
53
|
+
static styles: import("lit").CSSResult[];
|
|
54
|
+
constructor();
|
|
55
|
+
private handleRemove;
|
|
56
|
+
private handleKeyDown;
|
|
57
|
+
render(): import("lit-html").TemplateResult<1>;
|
|
58
|
+
}
|
|
59
|
+
declare global {
|
|
60
|
+
interface HTMLElementTagNameMap {
|
|
61
|
+
'bp-tag': BpTag;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
//# sourceMappingURL=tag.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tag.d.ts","sourceRoot":"","sources":["../../../source/components/tag/tag.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAQ,MAAM,KAAK,CAAC;AAIvC,OAAO,iBAAiB,CAAC;AAEzB;;;;;;;;;;;;;;;;;;GAkBG;AACH,qBACa,KAAM,SAAQ,UAAU;IACnC;;;;OAIG;IACgD,OAAO,EACtD,OAAO,GACP,UAAU,CAAC;IAEf;;;;OAIG;IACgD,IAAI,EACnD,IAAI,GACJ,IAAI,GACJ,IAAI,CAAC;IAET;;;;OAIG;IACgD,KAAK,EACpD,SAAS,GACT,SAAS,GACT,OAAO,GACP,SAAS,GACT,MAAM,GACN,SAAS,CAAC;IAEd;;;;OAIG;IACiD,SAAS,EAAE,OAAO,CAAC;IAEvE;;;;OAIG;IACiD,QAAQ,EAAE,OAAO,CAAC;IAEtE,MAAM,CAAC,MAAM,4BAAe;;IAW5B,OAAO,CAAC,YAAY;IAyBpB,OAAO,CAAC,aAAa;IAoBrB,MAAM;CA4CP;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,QAAQ,EAAE,KAAK,CAAC;KACjB;CACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tag.style.d.ts","sourceRoot":"","sources":["../../../source/components/tag/tag.style.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,SAAS,yBAqMrB,CAAC"}
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
import { LitElement } from 'lit';
|
|
2
|
+
export type TextElement = 'p' | 'span' | 'div';
|
|
3
|
+
export type TextSize = 'xs' | 'sm' | 'base' | 'lg' | 'xl';
|
|
4
|
+
export type TextWeight = 'light' | 'normal' | 'medium' | 'semibold' | 'bold';
|
|
5
|
+
export type TextVariant = 'default' | 'muted' | 'primary' | 'success' | 'warning' | 'error';
|
|
6
|
+
export type TextAlign = 'left' | 'center' | 'right' | 'justify';
|
|
7
|
+
export type TextTransform = 'none' | 'uppercase' | 'lowercase' | 'capitalize';
|
|
8
|
+
export type TextTracking = 'tighter' | 'tight' | 'normal' | 'wide' | 'wider';
|
|
9
|
+
export type TextLineHeight = 'none' | 'tight' | 'snug' | 'normal' | 'relaxed' | 'loose';
|
|
10
|
+
/**
|
|
11
|
+
* A typography component for body text with flexible styling options.
|
|
12
|
+
*
|
|
13
|
+
* @element bp-text
|
|
14
|
+
*
|
|
15
|
+
* @property {TextElement} as - The HTML element type to render
|
|
16
|
+
* @property {TextSize} size - The size of the text
|
|
17
|
+
* @property {TextWeight} weight - The font weight
|
|
18
|
+
* @property {TextVariant} variant - The color variant
|
|
19
|
+
* @property {TextAlign} align - Text alignment
|
|
20
|
+
* @property {TextTransform} transform - Text transformation (uppercase, lowercase, capitalize)
|
|
21
|
+
* @property {TextTracking} tracking - Letter spacing
|
|
22
|
+
* @property {TextLineHeight} lineHeight - Line height variant
|
|
23
|
+
* @property {number} clamp - Number of lines to clamp (multi-line truncation)
|
|
24
|
+
* @property {boolean} italic - Whether the text is italic
|
|
25
|
+
* @property {boolean} truncate - Whether to truncate with ellipsis
|
|
26
|
+
*
|
|
27
|
+
* @slot - The text content
|
|
28
|
+
*
|
|
29
|
+
* @csspart text - The text container element
|
|
30
|
+
*/
|
|
31
|
+
export declare class BpText extends LitElement {
|
|
32
|
+
/**
|
|
33
|
+
* The element type to render.
|
|
34
|
+
*/
|
|
35
|
+
as: TextElement;
|
|
36
|
+
/**
|
|
37
|
+
* The size of the text.
|
|
38
|
+
*/
|
|
39
|
+
size: TextSize;
|
|
40
|
+
/**
|
|
41
|
+
* The font weight of the text.
|
|
42
|
+
*/
|
|
43
|
+
weight: TextWeight;
|
|
44
|
+
/**
|
|
45
|
+
* The color variant of the text.
|
|
46
|
+
*/
|
|
47
|
+
variant: TextVariant;
|
|
48
|
+
/**
|
|
49
|
+
* The text alignment.
|
|
50
|
+
*/
|
|
51
|
+
align: TextAlign;
|
|
52
|
+
/**
|
|
53
|
+
* Text transformation.
|
|
54
|
+
*/
|
|
55
|
+
transform: TextTransform;
|
|
56
|
+
/**
|
|
57
|
+
* Letter spacing (tracking).
|
|
58
|
+
*/
|
|
59
|
+
tracking: TextTracking;
|
|
60
|
+
/**
|
|
61
|
+
* Line height variant.
|
|
62
|
+
*/
|
|
63
|
+
lineHeight: TextLineHeight;
|
|
64
|
+
/**
|
|
65
|
+
* Number of lines to clamp (multi-line truncation).
|
|
66
|
+
* When set, text will be truncated to the specified number of lines.
|
|
67
|
+
*/
|
|
68
|
+
clamp: number;
|
|
69
|
+
/**
|
|
70
|
+
* Whether the text should be italic.
|
|
71
|
+
*/
|
|
72
|
+
italic: boolean;
|
|
73
|
+
/**
|
|
74
|
+
* Whether the text should be truncated with ellipsis.
|
|
75
|
+
*/
|
|
76
|
+
truncate: boolean;
|
|
77
|
+
static styles: import("lit").CSSResult[];
|
|
78
|
+
constructor();
|
|
79
|
+
render(): import("lit-html").TemplateResult<1>;
|
|
80
|
+
}
|
|
81
|
+
declare global {
|
|
82
|
+
interface HTMLElementTagNameMap {
|
|
83
|
+
'bp-text': BpText;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
//# sourceMappingURL=text.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"text.d.ts","sourceRoot":"","sources":["../../../source/components/text/text.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAQ,MAAM,KAAK,CAAC;AAIvC,MAAM,MAAM,WAAW,GAAG,GAAG,GAAG,MAAM,GAAG,KAAK,CAAC;AAC/C,MAAM,MAAM,QAAQ,GAAG,IAAI,GAAG,IAAI,GAAG,MAAM,GAAG,IAAI,GAAG,IAAI,CAAC;AAC1D,MAAM,MAAM,UAAU,GAAG,OAAO,GAAG,QAAQ,GAAG,QAAQ,GAAG,UAAU,GAAG,MAAM,CAAC;AAC7E,MAAM,MAAM,WAAW,GACnB,SAAS,GACT,OAAO,GACP,SAAS,GACT,SAAS,GACT,SAAS,GACT,OAAO,CAAC;AACZ,MAAM,MAAM,SAAS,GAAG,MAAM,GAAG,QAAQ,GAAG,OAAO,GAAG,SAAS,CAAC;AAChE,MAAM,MAAM,aAAa,GAAG,MAAM,GAAG,WAAW,GAAG,WAAW,GAAG,YAAY,CAAC;AAC9E,MAAM,MAAM,YAAY,GAAG,SAAS,GAAG,OAAO,GAAG,QAAQ,GAAG,MAAM,GAAG,OAAO,CAAC;AAC7E,MAAM,MAAM,cAAc,GACtB,MAAM,GACN,OAAO,GACP,MAAM,GACN,QAAQ,GACR,SAAS,GACT,OAAO,CAAC;AAEZ;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,qBACa,MAAO,SAAQ,UAAU;IACpC;;OAEG;IACgD,EAAE,EAAE,WAAW,CAAC;IAEnE;;OAEG;IACgD,IAAI,EAAE,QAAQ,CAAC;IAElE;;OAEG;IACgD,MAAM,EAAE,UAAU,CAAC;IAEtE;;OAEG;IACgD,OAAO,EAAE,WAAW,CAAC;IAExE;;OAEG;IACgD,KAAK,EAAE,SAAS,CAAC;IAEpE;;OAEG;IACgD,SAAS,EAAE,aAAa,CAAC;IAE5E;;OAEG;IACgD,QAAQ,EAAE,YAAY,CAAC;IAE1E;;OAEG;IAEK,UAAU,EAAE,cAAc,CAAC;IAEnC;;;OAGG;IACgD,KAAK,EAAE,MAAM,CAAC;IAEjE;;OAEG;IACiD,MAAM,EAAE,OAAO,CAAC;IAEpE;;OAEG;IACiD,QAAQ,EAAE,OAAO,CAAC;IAEtE,MAAM,CAAC,MAAM,4BAAgB;;IAiB7B,MAAM;CA8BP;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,SAAS,EAAE,MAAM,CAAC;KACnB;CACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"text.style.d.ts","sourceRoot":"","sources":["../../../source/components/text/text.style.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,UAAU,yBAyMtB,CAAC"}
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { LitElement } from 'lit';
|
|
2
|
+
/**
|
|
3
|
+
* Visual variant that affects the textarea border color and validation state
|
|
4
|
+
*/
|
|
5
|
+
export type TextareaVariant = 'default' | 'success' | 'error' | 'warning' | 'info';
|
|
6
|
+
/**
|
|
7
|
+
* Size of the textarea affecting padding, font size, and minimum height
|
|
8
|
+
*/
|
|
9
|
+
export type TextareaSize = 'sm' | 'md' | 'lg';
|
|
10
|
+
/**
|
|
11
|
+
* Resize mode determining how users can resize the textarea
|
|
12
|
+
*/
|
|
13
|
+
export type TextareaResize = 'none' | 'both' | 'horizontal' | 'vertical';
|
|
14
|
+
/**
|
|
15
|
+
* Valid autocomplete values for textarea elements
|
|
16
|
+
*/
|
|
17
|
+
export type TextareaAutocomplete = 'off' | 'on' | 'name' | 'email' | 'username' | 'street-address' | 'address-line1' | 'address-line2' | 'address-line3' | 'address-level1' | 'address-level2' | 'address-level3' | 'address-level4' | 'country' | 'country-name' | 'postal-code' | 'organization' | 'organization-title';
|
|
18
|
+
/**
|
|
19
|
+
* A multi-line text input component with support for various states and configurations.
|
|
20
|
+
*
|
|
21
|
+
* @fires bp-input - Dispatched when the textarea value changes (on every keystroke)
|
|
22
|
+
* @fires bp-change - Dispatched when the textarea loses focus after being changed
|
|
23
|
+
* @fires bp-focus - Dispatched when the textarea receives focus
|
|
24
|
+
* @fires bp-blur - Dispatched when the textarea loses focus
|
|
25
|
+
*/
|
|
26
|
+
export declare class BpTextarea extends LitElement {
|
|
27
|
+
/** Visual variant of the textarea */
|
|
28
|
+
variant: TextareaVariant;
|
|
29
|
+
/** Size of the textarea */
|
|
30
|
+
size: TextareaSize;
|
|
31
|
+
/** Current value of the textarea */
|
|
32
|
+
value: string;
|
|
33
|
+
/** Placeholder text shown when textarea is empty */
|
|
34
|
+
placeholder: string | undefined;
|
|
35
|
+
/** Label text displayed above the textarea */
|
|
36
|
+
label: string | undefined;
|
|
37
|
+
/** Helper text displayed below the textarea */
|
|
38
|
+
helperText: string | undefined;
|
|
39
|
+
/** Error message displayed when variant is 'error' */
|
|
40
|
+
errorMessage: string | undefined;
|
|
41
|
+
/** Whether the textarea is disabled */
|
|
42
|
+
disabled: boolean;
|
|
43
|
+
/** Whether the textarea is required */
|
|
44
|
+
required: boolean;
|
|
45
|
+
/** Whether the textarea is readonly */
|
|
46
|
+
readonly: boolean;
|
|
47
|
+
/** Name attribute for form submission */
|
|
48
|
+
name: string | undefined;
|
|
49
|
+
/** Number of visible text rows */
|
|
50
|
+
rows: number | undefined;
|
|
51
|
+
/** Number of visible text columns */
|
|
52
|
+
cols: number | undefined;
|
|
53
|
+
/** Maximum number of characters allowed */
|
|
54
|
+
maxlength: number | undefined;
|
|
55
|
+
/** Minimum number of characters required */
|
|
56
|
+
minlength: number | undefined;
|
|
57
|
+
/** How the textarea can be resized by the user */
|
|
58
|
+
resize: TextareaResize;
|
|
59
|
+
/** Autocomplete attribute for browser suggestions */
|
|
60
|
+
autocomplete: TextareaAutocomplete | undefined;
|
|
61
|
+
/** Whether to enable spellcheck */
|
|
62
|
+
spellcheck: boolean;
|
|
63
|
+
/** Wrap attribute for text wrapping behavior */
|
|
64
|
+
wrap: 'soft' | 'hard' | undefined;
|
|
65
|
+
private textareaElement?;
|
|
66
|
+
private debouncedDispatchInput;
|
|
67
|
+
static styles: import("lit").CSSResult[];
|
|
68
|
+
constructor();
|
|
69
|
+
disconnectedCallback(): void;
|
|
70
|
+
private handleInput;
|
|
71
|
+
private handleChange;
|
|
72
|
+
private handleFocus;
|
|
73
|
+
private handleBlur;
|
|
74
|
+
/**
|
|
75
|
+
* Focuses the textarea element
|
|
76
|
+
*/
|
|
77
|
+
focus(): void;
|
|
78
|
+
/**
|
|
79
|
+
* Blurs the textarea element
|
|
80
|
+
*/
|
|
81
|
+
blur(): void;
|
|
82
|
+
/**
|
|
83
|
+
* Selects the text in the textarea
|
|
84
|
+
*/
|
|
85
|
+
select(): void;
|
|
86
|
+
private get messageId();
|
|
87
|
+
render(): import("lit-html").TemplateResult<1>;
|
|
88
|
+
}
|
|
89
|
+
declare global {
|
|
90
|
+
interface HTMLElementTagNameMap {
|
|
91
|
+
'bp-textarea': BpTextarea;
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
//# sourceMappingURL=textarea.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"textarea.d.ts","sourceRoot":"","sources":["../../../source/components/textarea/textarea.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAiB,MAAM,KAAK,CAAC;AAQhD;;GAEG;AACH,MAAM,MAAM,eAAe,GACvB,SAAS,GACT,SAAS,GACT,OAAO,GACP,SAAS,GACT,MAAM,CAAC;AAEX;;GAEG;AACH,MAAM,MAAM,YAAY,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAE9C;;GAEG;AACH,MAAM,MAAM,cAAc,GAAG,MAAM,GAAG,MAAM,GAAG,YAAY,GAAG,UAAU,CAAC;AAEzE;;GAEG;AACH,MAAM,MAAM,oBAAoB,GAC5B,KAAK,GACL,IAAI,GACJ,MAAM,GACN,OAAO,GACP,UAAU,GACV,gBAAgB,GAChB,eAAe,GACf,eAAe,GACf,eAAe,GACf,gBAAgB,GAChB,gBAAgB,GAChB,gBAAgB,GAChB,gBAAgB,GAChB,SAAS,GACT,cAAc,GACd,aAAa,GACb,cAAc,GACd,oBAAoB,CAAC;AAEzB;;;;;;;GAOG;AACH,qBACa,UAAW,SAAQ,UAAU;IACxC,qCAAqC;IACc,OAAO,EAAE,eAAe,CAAC;IAE5E,2BAA2B;IACwB,IAAI,EAAE,YAAY,CAAC;IAEtE,oCAAoC;IACe,KAAK,EAAE,MAAM,CAAC;IAEjE,oDAAoD;IACD,WAAW,EAC1D,MAAM,GACN,SAAS,CAAC;IAEd,8CAA8C;IACK,KAAK,EAAE,MAAM,GAAG,SAAS,CAAC;IAE7E,+CAA+C;IACI,UAAU,EACzD,MAAM,GACN,SAAS,CAAC;IAEd,sDAAsD;IACH,YAAY,EAC3D,MAAM,GACN,SAAS,CAAC;IAEd,uCAAuC;IACa,QAAQ,EAAE,OAAO,CAAC;IAEtE,uCAAuC;IACa,QAAQ,EAAE,OAAO,CAAC;IAEtE,uCAAuC;IACa,QAAQ,EAAE,OAAO,CAAC;IAEtE,yCAAyC;IACU,IAAI,EAAE,MAAM,GAAG,SAAS,CAAC;IAE5E,kCAAkC;IACiB,IAAI,EAAE,MAAM,GAAG,SAAS,CAAC;IAE5E,qCAAqC;IACc,IAAI,EAAE,MAAM,GAAG,SAAS,CAAC;IAE5E,2CAA2C;IACQ,SAAS,EACxD,MAAM,GACN,SAAS,CAAC;IAEd,4CAA4C;IACO,SAAS,EACxD,MAAM,GACN,SAAS,CAAC;IAEd,kDAAkD;IACC,MAAM,EAAE,cAAc,CAAC;IAE1E,qDAAqD;IACF,YAAY,EAC3D,oBAAoB,GACpB,SAAS,CAAC;IAEd,mCAAmC;IAE3B,UAAU,EAAE,OAAO,CAAC;IAE5B,gDAAgD;IACG,IAAI,EACnD,MAAM,GACN,MAAM,GACN,SAAS,CAAC;IAEK,OAAO,CAAC,eAAe,CAAC,CAAsB;IAEjE,OAAO,CAAC,sBAAsB,CAW5B;IAEF,MAAM,CAAC,MAAM,4BAAoB;;IAcjC,oBAAoB;IAKpB,OAAO,CAAC,WAAW;IAMnB,OAAO,CAAC,YAAY;IAapB,OAAO,CAAC,WAAW;IAUnB,OAAO,CAAC,UAAU;IAWlB;;OAEG;IACI,KAAK,IAAI,IAAI;IAIpB;;OAEG;IACI,IAAI,IAAI,IAAI;IAInB;;OAEG;IACI,MAAM,IAAI,IAAI;IAIrB,OAAO,KAAK,SAAS,GAMpB;IAED,MAAM;CA8DP;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,aAAa,EAAE,UAAU,CAAC;KAC3B;CACF"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"textarea.style.d.ts","sourceRoot":"","sources":["../../../source/components/textarea/textarea.style.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,cAAc,yBAgL1B,CAAC"}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { LitElement } from 'lit';
|
|
2
|
+
export type TimePickerSize = 'sm' | 'md' | 'lg';
|
|
3
|
+
export type TimeFormat = '12' | '24';
|
|
4
|
+
/**
|
|
5
|
+
* A time picker component with dropdown time selection.
|
|
6
|
+
*
|
|
7
|
+
* @element bp-time-picker
|
|
8
|
+
*
|
|
9
|
+
* @fires bp-change - Fired when the selected time changes
|
|
10
|
+
*
|
|
11
|
+
* @csspart input-wrapper - The input wrapper container
|
|
12
|
+
* @csspart input - The text input field
|
|
13
|
+
* @csspart icon - The clock icon indicator
|
|
14
|
+
* @csspart clear-button - The clear button
|
|
15
|
+
* @csspart dropdown - The time options dropdown
|
|
16
|
+
* @csspart time-option - Individual time option in dropdown
|
|
17
|
+
*/
|
|
18
|
+
export declare class BpTimePicker extends LitElement {
|
|
19
|
+
value: string;
|
|
20
|
+
name: string;
|
|
21
|
+
label: string;
|
|
22
|
+
placeholder: string;
|
|
23
|
+
disabled: boolean;
|
|
24
|
+
required: boolean;
|
|
25
|
+
size: TimePickerSize;
|
|
26
|
+
format: TimeFormat;
|
|
27
|
+
step: number;
|
|
28
|
+
private isOpen;
|
|
29
|
+
private focusedHour;
|
|
30
|
+
private focusedMinute;
|
|
31
|
+
static styles: import("lit").CSSResult[];
|
|
32
|
+
constructor();
|
|
33
|
+
disconnectedCallback(): void;
|
|
34
|
+
private handleDocumentClick;
|
|
35
|
+
private toggleDropdown;
|
|
36
|
+
private parseTime;
|
|
37
|
+
private formatTime;
|
|
38
|
+
private getDisplayValue;
|
|
39
|
+
private generateTimeOptions;
|
|
40
|
+
private handleTimeSelect;
|
|
41
|
+
private handleClear;
|
|
42
|
+
private handleKeyDown;
|
|
43
|
+
private isSelected;
|
|
44
|
+
render(): import("lit-html").TemplateResult<1>;
|
|
45
|
+
}
|
|
46
|
+
declare global {
|
|
47
|
+
interface HTMLElementTagNameMap {
|
|
48
|
+
'bp-time-picker': BpTimePicker;
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
//# sourceMappingURL=time-picker.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"time-picker.d.ts","sourceRoot":"","sources":["../../../source/components/time-picker/time-picker.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAQ,MAAM,KAAK,CAAC;AAKvC,MAAM,MAAM,cAAc,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAChD,MAAM,MAAM,UAAU,GAAG,IAAI,GAAG,IAAI,CAAC;AAErC;;;;;;;;;;;;;GAaG;AACH,qBACa,YAAa,SAAQ,UAAU;IACN,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,EAAE,OAAO,CAAC;IACnB,IAAI,EAAE,cAAc,CAAC;IACrB,MAAM,EAAE,UAAU,CAAC;IACnB,IAAI,EAAE,MAAM,CAAC;IAExC,OAAO,CAAC,MAAM,CAAS;IACvB,OAAO,CAAC,WAAW,CAAuB;IAC1C,OAAO,CAAC,aAAa,CAAuB;IAErD,MAAM,CAAC,MAAM,4BAAsB;;IAenC,oBAAoB;IAKpB,OAAO,CAAC,mBAAmB,CAIzB;IAEF,OAAO,CAAC,cAAc,CAqBpB;IAEF,OAAO,CAAC,SAAS;IAsBjB,OAAO,CAAC,UAAU;IAUlB,OAAO,CAAC,eAAe;IASvB,OAAO,CAAC,mBAAmB;IAqC3B,OAAO,CAAC,gBAAgB;IAgBxB,OAAO,CAAC,WAAW;IAmBnB,OAAO,CAAC,aAAa;IAoCrB,OAAO,CAAC,UAAU;IAMlB,MAAM;CAsGP;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,gBAAgB,EAAE,YAAY,CAAC;KAChC;CACF"}
|