@schandlergarcia/sf-web-components 1.0.7 ā 1.0.9
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/dist/components/library/index.d.ts +3 -3
- package/dist/index.js +180 -177
- package/package.json +1 -1
- package/scripts/remove-local-components.mjs +78 -0
|
@@ -1,8 +1,5 @@
|
|
|
1
|
-
export { default as UIButton } from "./ui/Button";
|
|
2
|
-
export { default as UIInput } from "./ui/Input";
|
|
3
1
|
export { default as UIToggle } from "./ui/Toggle";
|
|
4
2
|
export { default as UIText } from "./ui/Text";
|
|
5
|
-
export { default as UICard } from "./ui/Card";
|
|
6
3
|
export { default as UIContainer } from "./ui/Container";
|
|
7
4
|
export { default as UIChip } from "./ui/Chip";
|
|
8
5
|
export { default as Avatar } from "./ui/Avatar";
|
|
@@ -34,6 +31,9 @@ export { default as HeroUIInput } from "./heroui/Input";
|
|
|
34
31
|
export { default as HeroUICard } from "./heroui/Card";
|
|
35
32
|
export { default as HeroUIToggle } from "./heroui/Toggle";
|
|
36
33
|
export { default as AppThemeProvider, useThemeMode } from "./theme/AppThemeProvider";
|
|
34
|
+
export { default as UIButton, default as Button } from "./ui/Button";
|
|
35
|
+
export { default as UIInput, default as Input } from "./ui/Input";
|
|
36
|
+
export { default as UICard, default as Card } from "./ui/Card";
|
|
37
37
|
export { FormModal, FormRenderer, FormSection, FormField, useFormState } from "./forms";
|
|
38
38
|
export { FilterBar, SearchFilter, SelectFilter, ToggleFilter } from "./filters";
|
|
39
39
|
export { default as DataModeProvider, useDataMode } from "./data/DataModeProvider";
|
package/dist/index.js
CHANGED
|
@@ -1,185 +1,188 @@
|
|
|
1
1
|
import { cn as o } from "./lib/utils.js";
|
|
2
2
|
import { default as t, useThemeMode as f } from "./components/library/theme/AppThemeProvider.js";
|
|
3
|
-
import { default as d } from "./components/library/ui/Button.js";
|
|
4
|
-
import { default as
|
|
5
|
-
import { default as
|
|
6
|
-
import { default as
|
|
7
|
-
import { default as
|
|
8
|
-
import { default as
|
|
9
|
-
import { default as
|
|
10
|
-
import { default as
|
|
11
|
-
import { default as
|
|
12
|
-
import { default as
|
|
13
|
-
import { default as
|
|
14
|
-
import { default as
|
|
15
|
-
import { default as
|
|
16
|
-
import { default as
|
|
17
|
-
import { default as
|
|
18
|
-
import { default as
|
|
19
|
-
import { default as
|
|
20
|
-
import { default as
|
|
21
|
-
import { default as
|
|
22
|
-
import { default as
|
|
23
|
-
import { default as
|
|
24
|
-
import { default as
|
|
25
|
-
import { default as
|
|
26
|
-
import { default as
|
|
27
|
-
import { D3ChartTemplates as
|
|
28
|
-
import { default as
|
|
29
|
-
import { default as
|
|
30
|
-
import { default as
|
|
31
|
-
import { default as
|
|
32
|
-
import { default as
|
|
33
|
-
import { default as
|
|
34
|
-
import { default as
|
|
35
|
-
import { default as
|
|
36
|
-
import { default as
|
|
37
|
-
import { default as
|
|
38
|
-
import { default as
|
|
39
|
-
import { default as
|
|
40
|
-
import { default as
|
|
41
|
-
import { default as
|
|
42
|
-
import { default as
|
|
43
|
-
import { default as
|
|
44
|
-
import { applyFilters as
|
|
45
|
-
import { default as
|
|
46
|
-
import { default as
|
|
47
|
-
import { default as
|
|
48
|
-
import { default as
|
|
49
|
-
import { default as
|
|
50
|
-
import { default as
|
|
51
|
-
import { default as
|
|
52
|
-
import { default as
|
|
53
|
-
import { default as
|
|
54
|
-
import { default as
|
|
55
|
-
import { default as
|
|
56
|
-
import { default as
|
|
57
|
-
import { default as
|
|
58
|
-
import { default as
|
|
59
|
-
import { default as
|
|
60
|
-
import { default as
|
|
61
|
-
import { default as
|
|
62
|
-
import { default as
|
|
63
|
-
import { default as
|
|
64
|
-
import { default as
|
|
65
|
-
import { default as
|
|
66
|
-
import { default as
|
|
67
|
-
import { default as
|
|
68
|
-
import { default as
|
|
69
|
-
import { default as
|
|
70
|
-
import { default as
|
|
71
|
-
import { default as
|
|
72
|
-
import { default as
|
|
73
|
-
import { default as
|
|
74
|
-
import { default as
|
|
75
|
-
import { default as
|
|
76
|
-
import { default as
|
|
77
|
-
import { default as
|
|
78
|
-
import { Accordion as
|
|
3
|
+
import { default as d, default as s } from "./components/library/ui/Button.js";
|
|
4
|
+
import { default as u, default as m } from "./components/library/ui/Input.js";
|
|
5
|
+
import { default as i } from "./components/library/ui/Toggle.js";
|
|
6
|
+
import { default as I } from "./components/library/ui/Text.js";
|
|
7
|
+
import { default as U, default as g } from "./components/library/ui/Card.js";
|
|
8
|
+
import { default as S } from "./components/library/ui/Container.js";
|
|
9
|
+
import { default as h } from "./components/library/ui/Chip.js";
|
|
10
|
+
import { default as B } from "./components/library/ui/Avatar.js";
|
|
11
|
+
import { default as F } from "./components/library/ui/Spinner.js";
|
|
12
|
+
import { default as D } from "./components/library/ui/EmptyState.js";
|
|
13
|
+
import { default as A } from "./components/library/cards/BaseCard.js";
|
|
14
|
+
import { default as w } from "./components/library/cards/ChartCard.js";
|
|
15
|
+
import { default as k } from "./components/library/cards/ListCard.js";
|
|
16
|
+
import { default as L } from "./components/library/cards/MetricCard.js";
|
|
17
|
+
import { default as W } from "./components/library/cards/SectionCard.js";
|
|
18
|
+
import { default as G } from "./components/library/cards/StatusCard.js";
|
|
19
|
+
import { default as j } from "./components/library/cards/TableCard.js";
|
|
20
|
+
import { default as z } from "./components/library/cards/WidgetCard.js";
|
|
21
|
+
import { default as N } from "./components/library/cards/FeedPanel.js";
|
|
22
|
+
import { default as Q } from "./components/library/cards/ActivityCard.js";
|
|
23
|
+
import { default as Y } from "./components/library/cards/MetricsStrip.js";
|
|
24
|
+
import { default as _ } from "./components/library/cards/CalloutCard.js";
|
|
25
|
+
import { default as ee } from "./components/library/cards/ActionList.js";
|
|
26
|
+
import { default as oe } from "./components/library/charts/D3Chart.js";
|
|
27
|
+
import { D3ChartTemplates as te } from "./components/library/charts/D3ChartTemplates.js";
|
|
28
|
+
import { default as le } from "./components/library/charts/GeoMap.js";
|
|
29
|
+
import { default as se } from "./components/library/layout/PageContainer.js";
|
|
30
|
+
import { default as ue } from "./components/library/skeletons/CardSkeleton.js";
|
|
31
|
+
import { default as xe } from "./components/library/forms/FormModal.js";
|
|
32
|
+
import { default as ne } from "./components/library/forms/FormRenderer.js";
|
|
33
|
+
import { default as Ce } from "./components/library/forms/FormSection.js";
|
|
34
|
+
import { default as ge } from "./components/library/forms/FormField.js";
|
|
35
|
+
import { default as Se } from "./components/library/forms/useFormState.js";
|
|
36
|
+
import { default as he } from "./components/library/filters/FilterBar.js";
|
|
37
|
+
import { default as Be } from "./components/library/filters/SearchFilter.js";
|
|
38
|
+
import { default as Fe } from "./components/library/filters/SelectFilter.js";
|
|
39
|
+
import { default as De } from "./components/library/filters/ToggleFilter.js";
|
|
40
|
+
import { default as Ae, useDataMode as be } from "./components/library/data/DataModeProvider.js";
|
|
41
|
+
import { default as ve } from "./components/library/data/DataModeToggle.js";
|
|
42
|
+
import { default as Ke } from "./components/library/data/useDataSource.js";
|
|
43
|
+
import { default as Re } from "./components/library/data/usePageFilters.js";
|
|
44
|
+
import { applyFilters as Ee, filterByDateRange as Ge, filterBySearch as Ve, filterByToggle as je, filterByValue as qe, sortByKey as ze } from "./components/library/data/filterUtils.js";
|
|
45
|
+
import { default as Ne } from "./components/library/chat/ChatPanel.js";
|
|
46
|
+
import { default as Qe } from "./components/library/chat/ChatBar.js";
|
|
47
|
+
import { default as Ye } from "./components/library/chat/ChatMessageList.js";
|
|
48
|
+
import { default as _e } from "./components/library/chat/ChatMessage.js";
|
|
49
|
+
import { default as er } from "./components/library/chat/ChatInput.js";
|
|
50
|
+
import { default as or } from "./components/library/chat/ChatTypingIndicator.js";
|
|
51
|
+
import { default as tr } from "./components/library/chat/ChatSuggestions.js";
|
|
52
|
+
import { default as lr } from "./components/library/chat/ChatToolCall.js";
|
|
53
|
+
import { default as sr } from "./components/library/chat/ChatWelcome.js";
|
|
54
|
+
import { default as ur } from "./components/library/chat/useChatState.js";
|
|
55
|
+
import { default as xr } from "./components/library/heroui/Button.js";
|
|
56
|
+
import { default as nr } from "./components/library/heroui/Input.js";
|
|
57
|
+
import { default as Cr } from "./components/library/heroui/Card.js";
|
|
58
|
+
import { default as gr } from "./components/library/heroui/Toggle.js";
|
|
59
|
+
import { default as Sr } from "./components/library/heroui/Tabs.js";
|
|
60
|
+
import { default as hr } from "./components/library/heroui/Accordion.js";
|
|
61
|
+
import { default as Br } from "./components/library/heroui/Breadcrumbs.js";
|
|
62
|
+
import { default as Fr } from "./components/library/heroui/Separator.js";
|
|
63
|
+
import { default as Dr } from "./components/library/heroui/Pagination.js";
|
|
64
|
+
import { default as Ar } from "./components/library/heroui/Drawer.js";
|
|
65
|
+
import { default as wr } from "./components/library/heroui/Modal.js";
|
|
66
|
+
import { default as kr } from "./components/library/heroui/Dropdown.js";
|
|
67
|
+
import { default as Lr } from "./components/library/heroui/Tooltip.js";
|
|
68
|
+
import { default as Wr } from "./components/library/heroui/Toast.js";
|
|
69
|
+
import { default as Gr } from "./components/library/heroui/Alert.js";
|
|
70
|
+
import { default as jr } from "./components/library/heroui/Badge.js";
|
|
71
|
+
import { default as zr } from "./components/library/heroui/ProgressBar.js";
|
|
72
|
+
import { default as Nr } from "./components/library/heroui/ProgressCircle.js";
|
|
73
|
+
import { default as Qr } from "./components/library/heroui/Meter.js";
|
|
74
|
+
import { default as Yr } from "./components/library/heroui/Skeleton.js";
|
|
75
|
+
import { default as _r } from "./components/library/heroui/Select.js";
|
|
76
|
+
import { default as eo } from "./components/library/heroui/Kbd.js";
|
|
77
|
+
import { default as oo } from "./components/library/heroui/ScrollShadow.js";
|
|
78
|
+
import { Accordion as to, Alert as fo, Badge as lo, Breadcrumbs as so, Drawer as po, Dropdown as uo, Kbd as mo, Meter as xo, Modal as io, Pagination as no, ProgressBar as Io, ProgressCircle as Co, ScrollShadow as Uo, Select as go, Separator as co, Skeleton as So, Tabs as Ho, Toast as ho, Tooltip as To, toast as Bo } from "@heroui/react";
|
|
79
79
|
export {
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
80
|
+
to as Accordion,
|
|
81
|
+
ee as ActionList,
|
|
82
|
+
Q as ActivityCard,
|
|
83
|
+
fo as Alert,
|
|
84
84
|
t as AppThemeProvider,
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
85
|
+
B as Avatar,
|
|
86
|
+
lo as Badge,
|
|
87
|
+
A as BaseCard,
|
|
88
|
+
so as Breadcrumbs,
|
|
89
|
+
d as Button,
|
|
90
|
+
_ as CalloutCard,
|
|
91
|
+
U as Card,
|
|
92
|
+
ue as CardSkeleton,
|
|
93
|
+
w as ChartCard,
|
|
94
|
+
Qe as ChatBar,
|
|
95
|
+
er as ChatInput,
|
|
96
|
+
_e as ChatMessage,
|
|
97
|
+
Ye as ChatMessageList,
|
|
98
|
+
Ne as ChatPanel,
|
|
99
|
+
tr as ChatSuggestions,
|
|
100
|
+
lr as ChatToolCall,
|
|
101
|
+
or as ChatTypingIndicator,
|
|
102
|
+
sr as ChatWelcome,
|
|
103
|
+
oe as D3Chart,
|
|
104
|
+
te as D3ChartTemplates,
|
|
105
|
+
Ae as DataModeProvider,
|
|
106
|
+
ve as DataModeToggle,
|
|
107
|
+
po as Drawer,
|
|
108
|
+
uo as Dropdown,
|
|
109
|
+
D as EmptyState,
|
|
110
|
+
N as FeedPanel,
|
|
111
|
+
he as FilterBar,
|
|
112
|
+
ge as FormField,
|
|
113
|
+
xe as FormModal,
|
|
114
|
+
ne as FormRenderer,
|
|
115
|
+
Ce as FormSection,
|
|
116
|
+
le as GeoMap,
|
|
117
|
+
hr as HeroUIAccordion,
|
|
118
|
+
Gr as HeroUIAlert,
|
|
119
|
+
jr as HeroUIBadge,
|
|
120
|
+
Br as HeroUIBreadcrumbs,
|
|
121
|
+
xr as HeroUIButton,
|
|
122
|
+
Cr as HeroUICard,
|
|
123
|
+
Ar as HeroUIDrawer,
|
|
124
|
+
kr as HeroUIDropdown,
|
|
125
|
+
nr as HeroUIInput,
|
|
126
|
+
eo as HeroUIKbd,
|
|
127
|
+
Qr as HeroUIMeter,
|
|
128
|
+
wr as HeroUIModal,
|
|
129
|
+
Dr as HeroUIPagination,
|
|
130
|
+
zr as HeroUIProgressBar,
|
|
131
|
+
Nr as HeroUIProgressCircle,
|
|
132
|
+
oo as HeroUIScrollShadow,
|
|
133
|
+
_r as HeroUISelect,
|
|
134
|
+
Fr as HeroUISeparator,
|
|
135
|
+
Yr as HeroUISkeleton,
|
|
136
|
+
Sr as HeroUITabs,
|
|
137
|
+
Wr as HeroUIToast,
|
|
138
|
+
gr as HeroUIToggle,
|
|
139
|
+
Lr as HeroUITooltip,
|
|
140
|
+
u as Input,
|
|
141
|
+
mo as Kbd,
|
|
142
|
+
k as ListCard,
|
|
143
|
+
xo as Meter,
|
|
144
|
+
L as MetricCard,
|
|
145
|
+
Y as MetricsStrip,
|
|
146
|
+
io as Modal,
|
|
147
|
+
se as PageContainer,
|
|
148
|
+
no as Pagination,
|
|
149
|
+
Io as ProgressBar,
|
|
150
|
+
Co as ProgressCircle,
|
|
151
|
+
Uo as ScrollShadow,
|
|
152
|
+
Be as SearchFilter,
|
|
153
|
+
W as SectionCard,
|
|
154
|
+
go as Select,
|
|
155
|
+
Fe as SelectFilter,
|
|
156
|
+
co as Separator,
|
|
157
|
+
So as Skeleton,
|
|
158
|
+
F as Spinner,
|
|
159
|
+
G as StatusCard,
|
|
160
|
+
j as TableCard,
|
|
161
|
+
Ho as Tabs,
|
|
162
|
+
ho as Toast,
|
|
163
|
+
De as ToggleFilter,
|
|
164
|
+
To as Tooltip,
|
|
165
|
+
s as UIButton,
|
|
166
|
+
g as UICard,
|
|
167
|
+
h as UIChip,
|
|
168
|
+
S as UIContainer,
|
|
169
|
+
m as UIInput,
|
|
170
|
+
I as UIText,
|
|
171
|
+
i as UIToggle,
|
|
172
|
+
z as WidgetCard,
|
|
173
|
+
Ee as applyFilters,
|
|
171
174
|
o as cn,
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
175
|
+
Ge as filterByDateRange,
|
|
176
|
+
Ve as filterBySearch,
|
|
177
|
+
je as filterByToggle,
|
|
178
|
+
qe as filterByValue,
|
|
179
|
+
ze as sortByKey,
|
|
180
|
+
Bo as toast,
|
|
181
|
+
ur as useChatState,
|
|
182
|
+
be as useDataMode,
|
|
183
|
+
Ke as useDataSource,
|
|
184
|
+
Se as useFormState,
|
|
185
|
+
Re as usePageFilters,
|
|
183
186
|
f as useThemeMode
|
|
184
187
|
};
|
|
185
188
|
//# sourceMappingURL=index.js.map
|
package/package.json
CHANGED
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Remove Local Components Script
|
|
5
|
+
*
|
|
6
|
+
* Removes local shadcn/ui components and lib utilities after migrating to the component library.
|
|
7
|
+
* This script should be run from the consuming project's webapp directory.
|
|
8
|
+
*
|
|
9
|
+
* Usage:
|
|
10
|
+
* node node_modules/@schandlergarcia/sf-web-components/scripts/remove-local-components.mjs
|
|
11
|
+
*
|
|
12
|
+
* Or add to package.json:
|
|
13
|
+
* "scripts": {
|
|
14
|
+
* "remove-local-ui": "node node_modules/@schandlergarcia/sf-web-components/scripts/remove-local-components.mjs"
|
|
15
|
+
* }
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import fs from 'fs';
|
|
19
|
+
import path from 'path';
|
|
20
|
+
import { fileURLToPath } from 'url';
|
|
21
|
+
|
|
22
|
+
const __filename = fileURLToPath(import.meta.url);
|
|
23
|
+
const __dirname = path.dirname(__filename);
|
|
24
|
+
|
|
25
|
+
// Get the webapp root (where this script is being called from)
|
|
26
|
+
const webappRoot = process.cwd();
|
|
27
|
+
|
|
28
|
+
console.log('šļø Remove Local Components');
|
|
29
|
+
console.log('==========================\n');
|
|
30
|
+
console.log(`Working directory: ${webappRoot}\n`);
|
|
31
|
+
|
|
32
|
+
// Paths to remove
|
|
33
|
+
const pathsToRemove = [
|
|
34
|
+
'src/components/ui',
|
|
35
|
+
'src/lib/utils.ts',
|
|
36
|
+
'src/lib/utils.js'
|
|
37
|
+
];
|
|
38
|
+
|
|
39
|
+
let removedCount = 0;
|
|
40
|
+
const errors = [];
|
|
41
|
+
|
|
42
|
+
for (const pathToRemove of pathsToRemove) {
|
|
43
|
+
const fullPath = path.join(webappRoot, pathToRemove);
|
|
44
|
+
|
|
45
|
+
if (!fs.existsSync(fullPath)) {
|
|
46
|
+
console.log(` ā ${pathToRemove} (does not exist)`);
|
|
47
|
+
continue;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
try {
|
|
51
|
+
const stats = fs.statSync(fullPath);
|
|
52
|
+
|
|
53
|
+
if (stats.isDirectory()) {
|
|
54
|
+
fs.rmSync(fullPath, { recursive: true, force: true });
|
|
55
|
+
console.log(` ā Removed directory: ${pathToRemove}`);
|
|
56
|
+
} else {
|
|
57
|
+
fs.unlinkSync(fullPath);
|
|
58
|
+
console.log(` ā Removed file: ${pathToRemove}`);
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
removedCount++;
|
|
62
|
+
} catch (error) {
|
|
63
|
+
const errorMsg = `Failed to remove ${pathToRemove}: ${error.message}`;
|
|
64
|
+
errors.push(errorMsg);
|
|
65
|
+
console.error(` ā ${errorMsg}`);
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
console.log(`\nš Summary: Removed ${removedCount} items`);
|
|
70
|
+
|
|
71
|
+
if (errors.length > 0) {
|
|
72
|
+
console.error('\nā Errors:');
|
|
73
|
+
errors.forEach(e => console.error(` - ${e}`));
|
|
74
|
+
process.exit(1);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
console.log('\nā
Local components removed successfully!');
|
|
78
|
+
console.log('\nā¹ļø Note: All imports should now use @schandlergarcia/sf-web-components');
|