@ramme-io/ui 4.1.0 → 4.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -3
- package/dist/component-registry.js +55 -52
- package/dist/components/ai/AIChatThread/AIChatThread.js +3 -3
- package/dist/components/ai/NewsSummaryCard/NewsSummaryCard.js +17 -17
- package/dist/components/ai/StockChart/StockChart.js +4 -4
- package/dist/components/auth/LoginPage.d.ts +22 -0
- package/dist/components/auth/LoginPage.js +50 -42
- package/dist/components/forms/ComboBox.js +2 -2
- package/dist/components/forms/DatePicker.js +37 -32
- package/dist/components/forms/FileUpload.js +39 -37
- package/dist/components/forms/Input.js +19 -18
- package/dist/components/forms/MultiSelect.js +9 -8
- package/dist/components/forms/Select.js +9 -8
- package/dist/components/forms/Textarea.d.ts +13 -11
- package/dist/components/forms/Textarea.js +36 -16
- package/dist/components/layout/Accordion.js +25 -32
- package/dist/components/layout/Card.js +38 -21
- package/dist/components/layout/DetailDrawer.js +36 -37
- package/dist/components/layout/SettingsContainer.js +23 -13
- package/dist/components/layout/Sheet.d.ts +58 -0
- package/dist/components/layout/Sheet.js +144 -0
- package/dist/components/navigation/MobileNav.d.ts +44 -1
- package/dist/components/navigation/MobileNav.js +96 -70
- package/dist/components/navigation/Tabs.js +19 -12
- package/dist/components/ui/icon-loader.d.ts +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.js +218 -211
- package/dist/lib/hooks/useSheetGesture.d.ts +81 -0
- package/dist/lib/hooks/useSheetGesture.js +70 -0
- package/dist/setupTests.d.ts +1 -0
- package/dist/wizardManifest.js +130 -10
- package/package.json +9 -2
- package/src/wizardManifest.ts +130 -10
package/dist/index.js
CHANGED
|
@@ -6,19 +6,19 @@ import { Loader as n } from "./blocks/ai/Loader.js";
|
|
|
6
6
|
import { Actions as s, Suggestion as T } from "./blocks/ai/Actions.js";
|
|
7
7
|
import { PromptInput as h } from "./blocks/ai/PromptInput.js";
|
|
8
8
|
import { Message as c } from "./blocks/ai/Message.js";
|
|
9
|
-
import { Conversation as
|
|
9
|
+
import { Conversation as g } from "./blocks/ai/Conversation.js";
|
|
10
10
|
import { ChatFAB as b } from "./blocks/ai/ChatFAB.js";
|
|
11
|
-
import { AIChatThread as
|
|
12
|
-
import { KeyInjectionOverlay as
|
|
13
|
-
import { TAY_DREAMBOAT_THEME as
|
|
11
|
+
import { AIChatThread as I } from "./components/ai/AIChatThread/AIChatThread.js";
|
|
12
|
+
import { KeyInjectionOverlay as D } from "./components/ai/KeyInjectionOverlay.js";
|
|
13
|
+
import { TAY_DREAMBOAT_THEME as B, ThemeProvider as R, availableThemes as E, useTheme as v } from "./contexts/ThemeContext.js";
|
|
14
14
|
import { AuthLayout as y } from "./components/auth/AuthLayout.js";
|
|
15
|
-
import { LoginPage as
|
|
15
|
+
import { LoginPage as w } from "./components/auth/LoginPage.js";
|
|
16
16
|
import { SignupPage as O } from "./components/auth/SignupPage.js";
|
|
17
17
|
import { DataTable as H } from "./components/data-display/DataTable.js";
|
|
18
|
-
import { ActivityFeed as
|
|
19
|
-
import { Table as
|
|
20
|
-
import { AreaChart as
|
|
21
|
-
import { BarChart as
|
|
18
|
+
import { ActivityFeed as V } from "./components/data-display/ActivityFeed.js";
|
|
19
|
+
import { Table as N } from "./components/data-display/Table.js";
|
|
20
|
+
import { AreaChart as Y } from "./components/data-display/AreaChart.js";
|
|
21
|
+
import { BarChart as W } from "./components/data-display/BarChart.js";
|
|
22
22
|
import { ChartWithTable as j } from "./components/data-display/ChartWithTable.js";
|
|
23
23
|
import { LineChart as q } from "./components/data-display/LineChart.js";
|
|
24
24
|
import { PieChart as Z } from "./components/data-display/PieChart.js";
|
|
@@ -31,20 +31,20 @@ import { Alert as nr } from "./components/feedback/Alert.js";
|
|
|
31
31
|
import { EmptyState as sr } from "./components/feedback/EmptyState.js";
|
|
32
32
|
import { Skeleton as dr } from "./components/feedback/Skeleton.js";
|
|
33
33
|
import { Plan as Cr } from "./components/feedback/Plan.js";
|
|
34
|
-
import { TippyTooltip as
|
|
35
|
-
import { Toast as
|
|
36
|
-
import { ToastProvider as Pr, useToast as
|
|
37
|
-
import { Label as
|
|
38
|
-
import { ButtonGroup as
|
|
39
|
-
import { Checkbox as
|
|
34
|
+
import { TippyTooltip as Sr } from "./components/feedback/TippyTooltip.js";
|
|
35
|
+
import { Toast as ur } from "./components/feedback/Toast.js";
|
|
36
|
+
import { ToastProvider as Pr, useToast as Ir } from "./components/feedback/ToastProvider.js";
|
|
37
|
+
import { Label as Dr } from "./components/forms/Label.js";
|
|
38
|
+
import { ButtonGroup as Br } from "./components/forms/ButtonGroup.js";
|
|
39
|
+
import { Checkbox as Er } from "./components/forms/Checkbox.js";
|
|
40
40
|
import { ComboBox as Mr } from "./components/forms/ComboBox.js";
|
|
41
|
-
import { DatePicker as
|
|
41
|
+
import { DatePicker as Fr } from "./components/forms/DatePicker.js";
|
|
42
42
|
import { FileUpload as kr } from "./components/forms/FileUpload.js";
|
|
43
43
|
import { FormTemplate as _r } from "./components/forms/FormTemplate.js";
|
|
44
44
|
import { Input as Gr } from "./components/forms/Input.js";
|
|
45
|
-
import { MultiSelect as
|
|
45
|
+
import { MultiSelect as Kr } from "./components/forms/MultiSelect.js";
|
|
46
46
|
import { Radio as Ur } from "./components/forms/Radio.js";
|
|
47
|
-
import { SearchInput as
|
|
47
|
+
import { SearchInput as Qr } from "./components/forms/SearchInput.js";
|
|
48
48
|
import { SegmentedControl as zr } from "./components/forms/SegmentedControl.js";
|
|
49
49
|
import { Select as Xr } from "./components/forms/Select.js";
|
|
50
50
|
import { Textarea as Jr } from "./components/forms/Textarea.js";
|
|
@@ -53,241 +53,248 @@ import { useDataFetch as eo } from "./lib/hooks/useDataFetch.js";
|
|
|
53
53
|
import { useChartTheme as mo } from "./lib/hooks/useChartTheme.js";
|
|
54
54
|
import { MOBILE_BREAKPOINT_PX as po, MOBILE_BREAKPOINT_QUERY as fo, useIsMobile as xo, useMediaQuery as io } from "./lib/hooks/useMediaQuery.js";
|
|
55
55
|
import { useBodyScrollLock as lo } from "./lib/hooks/useBodyScrollLock.js";
|
|
56
|
-
import {
|
|
57
|
-
import {
|
|
58
|
-
import {
|
|
59
|
-
import {
|
|
60
|
-
import {
|
|
61
|
-
import {
|
|
62
|
-
import {
|
|
63
|
-
import {
|
|
64
|
-
import {
|
|
65
|
-
import {
|
|
66
|
-
import {
|
|
67
|
-
import {
|
|
68
|
-
import {
|
|
69
|
-
import {
|
|
70
|
-
import {
|
|
71
|
-
import {
|
|
72
|
-
import {
|
|
73
|
-
import {
|
|
74
|
-
import {
|
|
75
|
-
import {
|
|
76
|
-
import {
|
|
77
|
-
import {
|
|
78
|
-
import {
|
|
79
|
-
import {
|
|
80
|
-
import {
|
|
81
|
-
import {
|
|
82
|
-
import {
|
|
83
|
-
import {
|
|
84
|
-
import {
|
|
85
|
-
import {
|
|
86
|
-
import {
|
|
87
|
-
import {
|
|
88
|
-
import {
|
|
89
|
-
import {
|
|
90
|
-
import {
|
|
91
|
-
import {
|
|
92
|
-
import {
|
|
93
|
-
import {
|
|
94
|
-
import {
|
|
95
|
-
import {
|
|
96
|
-
import {
|
|
97
|
-
import {
|
|
98
|
-
import {
|
|
99
|
-
import {
|
|
100
|
-
import {
|
|
101
|
-
import {
|
|
102
|
-
import {
|
|
103
|
-
import {
|
|
104
|
-
import {
|
|
105
|
-
import {
|
|
106
|
-
import {
|
|
107
|
-
import {
|
|
108
|
-
import {
|
|
109
|
-
import {
|
|
110
|
-
import {
|
|
111
|
-
import {
|
|
112
|
-
import {
|
|
113
|
-
import {
|
|
114
|
-
import {
|
|
115
|
-
import {
|
|
116
|
-
import {
|
|
117
|
-
import {
|
|
118
|
-
import {
|
|
119
|
-
import {
|
|
120
|
-
import {
|
|
121
|
-
import {
|
|
122
|
-
import {
|
|
123
|
-
import {
|
|
56
|
+
import { DISMISS_THRESHOLD as To, FLICK_VELOCITY as ho, settleTo as Co, useSheetGesture as co } from "./lib/hooks/useSheetGesture.js";
|
|
57
|
+
import { CircularDial as go } from "./components/hardware/CircularDial.js";
|
|
58
|
+
import { HardwareCommandButton as bo } from "./components/hardware/HardwareCommandButton.js";
|
|
59
|
+
import { Sparkline as Io } from "./components/hardware/Sparkline.js";
|
|
60
|
+
import { EdgeInsightTerminal as Do } from "./components/hardware/EdgeInsightTerminal.js";
|
|
61
|
+
import { DeviceCard as Bo } from "./blocks/iot/DeviceCard.js";
|
|
62
|
+
import { WaterPumpControl as Eo } from "./blocks/iot/WaterPumpControl.js";
|
|
63
|
+
import { TelemetryLog as Mo } from "./blocks/iot/TelemetryLog.js";
|
|
64
|
+
import { DataCard as Fo } from "./components/molecular/DataCard.js";
|
|
65
|
+
import { StateMatrix as ko } from "./components/molecular/StateMatrix.js";
|
|
66
|
+
import { ConnectorOverlay as _o } from "./components/molecular/ConnectorOverlay.js";
|
|
67
|
+
import { AppShell as Go } from "./components/layout/AppShell.js";
|
|
68
|
+
import { SettingsContainer as Ko } from "./components/layout/SettingsContainer.js";
|
|
69
|
+
import { DetailDrawer as Uo } from "./components/layout/DetailDrawer.js";
|
|
70
|
+
import { RammeInspectorTrigger as Qo } from "./components/layout/RammeInspectorTrigger.js";
|
|
71
|
+
import { AboutRamme as zo } from "./components/layout/AboutRamme.js";
|
|
72
|
+
import { Header as Xo } from "./components/layout/Header.js";
|
|
73
|
+
import { Toolbar as Jo } from "./components/layout/Toolbar.js";
|
|
74
|
+
import { FilterPanel as $o } from "./components/layout/FilterPanel.js";
|
|
75
|
+
import { Statusbar as oe } from "./components/layout/Statusbar.js";
|
|
76
|
+
import { Accordion as te, AccordionItem as me } from "./components/layout/Accordion.js";
|
|
77
|
+
import { Card as pe, CardContent as fe, CardDescription as xe, CardFooter as ie, CardHeader as ne, CardLabel as le, CardTitle as se } from "./components/layout/Card.js";
|
|
78
|
+
import { Drawer as de } from "./components/layout/Drawer.js";
|
|
79
|
+
import { Sheet as Ce } from "./components/layout/Sheet.js";
|
|
80
|
+
import { DefinitionDescription as Se, DefinitionList as ge, DefinitionTerm as ue, List as be, ListItem as Pe } from "./components/layout/List.js";
|
|
81
|
+
import { Modal as Ae } from "./components/layout/Modal.js";
|
|
82
|
+
import { Sidebar as Le } from "./components/layout/Sidebar.js";
|
|
83
|
+
import { ActionBar as Re } from "./components/layout/ActionBar.js";
|
|
84
|
+
import { PageContainer as ve } from "./components/layout/PageContainer.js";
|
|
85
|
+
import { PageHeader as ye } from "./components/layout/PageHeader.js";
|
|
86
|
+
import { SectionHeader as we } from "./components/layout/SectionHeader.js";
|
|
87
|
+
import { ButtonItem as Oe, UserNav as _e } from "./components/layout/UserNav.js";
|
|
88
|
+
import { CollectionLayout as Ge } from "./components/layout/CollectionLayout.js";
|
|
89
|
+
import { DenseMetricRibbon as Ke } from "./components/layout/DenseMetricRibbon.js";
|
|
90
|
+
import { BreadcrumbItem as Ue, Breadcrumbs as Ye } from "./components/navigation/Breadcrumbs.js";
|
|
91
|
+
import { Menu as We, MenuDivider as ze, MenuItem as je } from "./components/navigation/Menu.js";
|
|
92
|
+
import { MobileNav as qe } from "./components/navigation/MobileNav.js";
|
|
93
|
+
import { Pagination as Ze } from "./components/navigation/Pagination.js";
|
|
94
|
+
import { Stepper as rt } from "./components/navigation/Stepper.js";
|
|
95
|
+
import { TabPanel as et, Tabs as tt } from "./components/navigation/Tabs.js";
|
|
96
|
+
import { FinancialAssetSchema as at, WatchlistEngine as pt } from "./blocks/engines/WatchlistEngine.js";
|
|
97
|
+
import { Avatar as xt } from "./components/ui/Avatar.js";
|
|
98
|
+
import { Badge as nt, badgeVariants as lt } from "./components/ui/Badge.js";
|
|
99
|
+
import { Button as Tt, buttonVariants as dt } from "./components/ui/Button.js";
|
|
100
|
+
import { Icon as Ct } from "./components/ui/Icon.js";
|
|
101
|
+
import { BrandLogo as St } from "./components/ui/BrandLogo.js";
|
|
102
|
+
import { cn as ut } from "./utils/cn.js";
|
|
103
|
+
import { formatValue as Pt } from "./lib/formatters.js";
|
|
104
|
+
import { ThemeSynthesizer as At } from "./components/theme/ThemeSynthesizer.js";
|
|
105
|
+
import { AestheticProfileGrid as Lt } from "./components/theme/AestheticProfileGrid.js";
|
|
106
|
+
import { FineTuningControls as Rt } from "./components/theme/FineTuningControls.js";
|
|
107
|
+
import { PaletteSwatch as vt, ThemeLivePreview as Mt } from "./components/theme/ThemeLivePreview.js";
|
|
108
|
+
import { ThemeSettings as Ft } from "./components/theme/ThemeSettings.js";
|
|
109
|
+
import { ThemeLab as kt } from "./components/theme/ThemeLab.js";
|
|
110
|
+
import { AESTHETIC_PROFILES as _t, generateFromProfile as Ht, generateFromPrompt as Gt, generateRandom as Vt, hslToCssString as Kt, hslToRgb as Nt, hslToRgbString as Ut, lightToDark as Yt, paletteToRgbVars as Qt } from "./lib/theme/ThemeGenerator.logic.js";
|
|
111
|
+
import { THEME_TOKEN_VARS as zt, applyThemeToDom as jt, generateRandomTheme as Xt, getContrastColor as qt, hexToRgbTriplet as Jt, isCustomTheme as Zt, loadGoogleFont as $t, randomRgb as rm, tokensToVars as om } from "./lib/theme/themeUtils.js";
|
|
112
|
+
import { generateThemeFromPrompt as tm } from "./lib/theme/themeAgent.js";
|
|
113
|
+
import { CompanyProfileCard as am } from "./components/ai/CompanyProfileCard/CompanyProfileCard.js";
|
|
114
|
+
import { CounterpartyGraphCard as fm } from "./components/ai/CounterpartyGraphCard/CounterpartyGraphCard.js";
|
|
115
|
+
import { DivergenceMetricsCard as im } from "./components/ai/DivergenceMetricsCard/DivergenceMetricsCard.js";
|
|
116
|
+
import { ArchitectureReferenceCard as lm } from "./components/ai/ArchitectureReferenceCard/ArchitectureReferenceCard.js";
|
|
117
|
+
import { LiveQuoteCard as Tm } from "./components/ai/LiveQuoteCard/LiveQuoteCard.js";
|
|
118
|
+
import { NewsSummaryCard as hm } from "./components/ai/NewsSummaryCard/NewsSummaryCard.js";
|
|
119
|
+
import { StockChart as cm } from "./components/ai/StockChart/StockChart.js";
|
|
120
|
+
import { TelemetryGraph as gm } from "./components/ai/TelemetryGraph/TelemetryGraph.js";
|
|
121
|
+
import { ShowroomContainer as bm } from "./components/showroom/ShowroomContainer.js";
|
|
122
|
+
import { ShowroomSidebar as Im } from "./components/showroom/ShowroomSidebar.js";
|
|
123
|
+
import { ShowroomCanvas as Dm } from "./components/showroom/ShowroomCanvas.js";
|
|
124
|
+
import { SkuBadge as Bm } from "./components/showroom/SkuBadge.js";
|
|
125
|
+
import { resolvePreview as Em } from "./components/showroom/ShowroomRenderer.js";
|
|
124
126
|
export {
|
|
125
|
-
|
|
126
|
-
|
|
127
|
+
_t as AESTHETIC_PROFILES,
|
|
128
|
+
I as AIChatThread,
|
|
127
129
|
a as AUTO_REGISTRY,
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
130
|
+
zo as AboutRamme,
|
|
131
|
+
te as Accordion,
|
|
132
|
+
me as AccordionItem,
|
|
133
|
+
Re as ActionBar,
|
|
132
134
|
s as Actions,
|
|
133
|
-
|
|
134
|
-
|
|
135
|
+
V as ActivityFeed,
|
|
136
|
+
Lt as AestheticProfileGrid,
|
|
135
137
|
nr as Alert,
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
138
|
+
Go as AppShell,
|
|
139
|
+
lm as ArchitectureReferenceCard,
|
|
140
|
+
Y as AreaChart,
|
|
139
141
|
y as AuthLayout,
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
142
|
+
xt as Avatar,
|
|
143
|
+
nt as Badge,
|
|
144
|
+
W as BarChart,
|
|
145
|
+
St as BrandLogo,
|
|
146
|
+
Ue as BreadcrumbItem,
|
|
147
|
+
Ye as Breadcrumbs,
|
|
148
|
+
Tt as Button,
|
|
149
|
+
Br as ButtonGroup,
|
|
150
|
+
Oe as ButtonItem,
|
|
151
|
+
pe as Card,
|
|
152
|
+
fe as CardContent,
|
|
153
|
+
xe as CardDescription,
|
|
154
|
+
ie as CardFooter,
|
|
155
|
+
ne as CardHeader,
|
|
156
|
+
le as CardLabel,
|
|
157
|
+
se as CardTitle,
|
|
156
158
|
j as ChartWithTable,
|
|
157
159
|
b as ChatFAB,
|
|
158
|
-
|
|
159
|
-
|
|
160
|
+
Er as Checkbox,
|
|
161
|
+
go as CircularDial,
|
|
160
162
|
er as CodeBlock,
|
|
161
|
-
|
|
163
|
+
Ge as CollectionLayout,
|
|
162
164
|
Mr as ComboBox,
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
165
|
+
am as CompanyProfileCard,
|
|
166
|
+
_o as ConnectorOverlay,
|
|
167
|
+
g as Conversation,
|
|
168
|
+
fm as CounterpartyGraphCard,
|
|
169
|
+
To as DISMISS_THRESHOLD,
|
|
170
|
+
Fo as DataCard,
|
|
168
171
|
H as DataTable,
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
172
|
+
Fr as DatePicker,
|
|
173
|
+
Se as DefinitionDescription,
|
|
174
|
+
ge as DefinitionList,
|
|
175
|
+
ue as DefinitionTerm,
|
|
176
|
+
Ke as DenseMetricRibbon,
|
|
177
|
+
Uo as DetailDrawer,
|
|
178
|
+
Bo as DeviceCard,
|
|
179
|
+
im as DivergenceMetricsCard,
|
|
180
|
+
de as Drawer,
|
|
181
|
+
Do as EdgeInsightTerminal,
|
|
179
182
|
sr as EmptyState,
|
|
183
|
+
ho as FLICK_VELOCITY,
|
|
180
184
|
kr as FileUpload,
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
185
|
+
$o as FilterPanel,
|
|
186
|
+
at as FinancialAssetSchema,
|
|
187
|
+
Rt as FineTuningControls,
|
|
184
188
|
_r as FormTemplate,
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
189
|
+
bo as HardwareCommandButton,
|
|
190
|
+
Xo as Header,
|
|
191
|
+
Ct as Icon,
|
|
188
192
|
Gr as Input,
|
|
189
|
-
|
|
193
|
+
D as KeyInjectionOverlay,
|
|
190
194
|
pr as KpiGrid,
|
|
191
|
-
|
|
195
|
+
Dr as Label,
|
|
192
196
|
q as LineChart,
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
197
|
+
be as List,
|
|
198
|
+
Pe as ListItem,
|
|
199
|
+
Tm as LiveQuoteCard,
|
|
196
200
|
n as Loader,
|
|
197
|
-
|
|
201
|
+
w as LoginPage,
|
|
198
202
|
po as MOBILE_BREAKPOINT_PX,
|
|
199
203
|
fo as MOBILE_BREAKPOINT_QUERY,
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
204
|
+
We as Menu,
|
|
205
|
+
ze as MenuDivider,
|
|
206
|
+
je as MenuItem,
|
|
203
207
|
c as Message,
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
208
|
+
qe as MobileNav,
|
|
209
|
+
Ae as Modal,
|
|
210
|
+
Kr as MultiSelect,
|
|
211
|
+
hm as NewsSummaryCard,
|
|
212
|
+
ve as PageContainer,
|
|
213
|
+
ye as PageHeader,
|
|
214
|
+
Ze as Pagination,
|
|
215
|
+
vt as PaletteSwatch,
|
|
212
216
|
Z as PieChart,
|
|
213
217
|
Cr as Plan,
|
|
214
218
|
h as PromptInput,
|
|
215
219
|
Ur as Radio,
|
|
216
|
-
|
|
220
|
+
Qo as RammeInspectorTrigger,
|
|
217
221
|
rr as ScatterChart,
|
|
218
|
-
|
|
219
|
-
|
|
222
|
+
Qr as SearchInput,
|
|
223
|
+
we as SectionHeader,
|
|
220
224
|
zr as SegmentedControl,
|
|
221
225
|
Xr as Select,
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
226
|
+
Ko as SettingsContainer,
|
|
227
|
+
Ce as Sheet,
|
|
228
|
+
Dm as ShowroomCanvas,
|
|
229
|
+
bm as ShowroomContainer,
|
|
230
|
+
Im as ShowroomSidebar,
|
|
231
|
+
Le as Sidebar,
|
|
227
232
|
O as SignupPage,
|
|
228
233
|
dr as Skeleton,
|
|
229
|
-
|
|
230
|
-
|
|
234
|
+
Bm as SkuBadge,
|
|
235
|
+
Io as Sparkline,
|
|
231
236
|
mr as StatCard,
|
|
232
|
-
|
|
237
|
+
ko as StateMatrix,
|
|
233
238
|
xr as StatusBadge,
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
239
|
+
oe as Statusbar,
|
|
240
|
+
rt as Stepper,
|
|
241
|
+
cm as StockChart,
|
|
237
242
|
T as Suggestion,
|
|
238
243
|
$r as Switch,
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
244
|
+
B as TAY_DREAMBOAT_THEME,
|
|
245
|
+
zt as THEME_TOKEN_VARS,
|
|
246
|
+
et as TabPanel,
|
|
247
|
+
N as Table,
|
|
248
|
+
tt as Tabs,
|
|
249
|
+
gm as TelemetryGraph,
|
|
250
|
+
Mo as TelemetryLog,
|
|
246
251
|
Jr as Textarea,
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
252
|
+
kt as ThemeLab,
|
|
253
|
+
Mt as ThemeLivePreview,
|
|
254
|
+
R as ThemeProvider,
|
|
255
|
+
Ft as ThemeSettings,
|
|
256
|
+
At as ThemeSynthesizer,
|
|
257
|
+
Sr as TippyTooltip,
|
|
258
|
+
ur as Toast,
|
|
254
259
|
Pr as ToastProvider,
|
|
255
260
|
ro as ToggleSwitch,
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
261
|
+
Jo as Toolbar,
|
|
262
|
+
_e as UserNav,
|
|
263
|
+
pt as WatchlistEngine,
|
|
264
|
+
Eo as WaterPumpControl,
|
|
265
|
+
jt as applyThemeToDom,
|
|
266
|
+
E as availableThemes,
|
|
267
|
+
lt as badgeVariants,
|
|
268
|
+
dt as buttonVariants,
|
|
269
|
+
ut as cn,
|
|
270
|
+
Pt as formatValue,
|
|
271
|
+
Ht as generateFromProfile,
|
|
272
|
+
Gt as generateFromPrompt,
|
|
273
|
+
Vt as generateRandom,
|
|
274
|
+
Xt as generateRandomTheme,
|
|
275
|
+
tm as generateThemeFromPrompt,
|
|
276
|
+
qt as getContrastColor,
|
|
277
|
+
Jt as hexToRgbTriplet,
|
|
278
|
+
Kt as hslToCssString,
|
|
279
|
+
Nt as hslToRgb,
|
|
280
|
+
Ut as hslToRgbString,
|
|
281
|
+
Zt as isCustomTheme,
|
|
282
|
+
Yt as lightToDark,
|
|
283
|
+
$t as loadGoogleFont,
|
|
279
284
|
f as mockChartData,
|
|
280
285
|
x as mockTableData,
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
286
|
+
Qt as paletteToRgbVars,
|
|
287
|
+
rm as randomRgb,
|
|
288
|
+
Em as resolvePreview,
|
|
289
|
+
Co as settleTo,
|
|
290
|
+
om as tokensToVars,
|
|
285
291
|
lo as useBodyScrollLock,
|
|
286
292
|
mo as useChartTheme,
|
|
287
293
|
eo as useDataFetch,
|
|
288
294
|
xo as useIsMobile,
|
|
289
295
|
io as useMediaQuery,
|
|
290
|
-
|
|
291
|
-
|
|
296
|
+
co as useSheetGesture,
|
|
297
|
+
v as useTheme,
|
|
298
|
+
Ir as useToast,
|
|
292
299
|
t as wizardManifest
|
|
293
300
|
};
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The gesture behind a bottom sheet.
|
|
3
|
+
*
|
|
4
|
+
* This is the library's first pointer-driven interaction. Nothing else in
|
|
5
|
+
* @ramme-io/ui uses Pointer Events at all — every interactive component is an
|
|
6
|
+
* HTML form element — so the rules it establishes are worth stating once:
|
|
7
|
+
*
|
|
8
|
+
* - **Pointer Events only.** One code path for touch, mouse, pen and trackpad.
|
|
9
|
+
* Separate `mousemove` and `touchmove` handlers are how you end up with a
|
|
10
|
+
* control that works on one and jitters on the other.
|
|
11
|
+
* - **`setPointerCapture`.** A drag must survive the finger leaving the
|
|
12
|
+
* element. Without capture, dragging a sheet up past its own top edge stops
|
|
13
|
+
* tracking, which reads as the sheet sticking.
|
|
14
|
+
* - **`touch-action: none`** on the drag surface, applied by the component.
|
|
15
|
+
* Without it the browser claims the gesture for scrolling and the sheet
|
|
16
|
+
* never moves.
|
|
17
|
+
*
|
|
18
|
+
* WHY THE SETTLE MATH IS A PURE FUNCTION
|
|
19
|
+
*
|
|
20
|
+
* jsdom has no layout and cannot drag, so the only honest way to test a gesture
|
|
21
|
+
* is to make its decisions independent of the DOM. `settleTo` below takes
|
|
22
|
+
* numbers and returns a number; every interesting rule — flick beats position,
|
|
23
|
+
* dragging below the smallest detent dismisses, a slow drag snaps to nearest —
|
|
24
|
+
* is checkable without a browser.
|
|
25
|
+
*/
|
|
26
|
+
/** Pixels per millisecond past which a drag counts as a flick rather than a move. */
|
|
27
|
+
export declare const FLICK_VELOCITY = 0.5;
|
|
28
|
+
/**
|
|
29
|
+
* How far below the smallest detent the sheet must be dragged before release
|
|
30
|
+
* dismisses it. Expressed as a fraction of the viewport so it scales with the
|
|
31
|
+
* screen rather than being generous on a tablet and twitchy on a phone.
|
|
32
|
+
*/
|
|
33
|
+
export declare const DISMISS_THRESHOLD = 0.12;
|
|
34
|
+
export interface SettleInput {
|
|
35
|
+
/** Current height of the sheet as a fraction of the viewport, 0–1. */
|
|
36
|
+
current: number;
|
|
37
|
+
/** Allowed resting heights, ascending fractions of the viewport. */
|
|
38
|
+
detents: number[];
|
|
39
|
+
/**
|
|
40
|
+
* Vertical velocity in px/ms. NEGATIVE is upward (the sheet growing), matching
|
|
41
|
+
* pointer coordinates where y decreases toward the top of the screen.
|
|
42
|
+
*/
|
|
43
|
+
velocity: number;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Where the sheet should come to rest when the finger lifts.
|
|
47
|
+
*
|
|
48
|
+
* Returns the target detent, or `null` meaning "dismiss".
|
|
49
|
+
*
|
|
50
|
+
* Order matters: a flick is honoured before position, because a fast downward
|
|
51
|
+
* flick from near the top should close the sheet rather than snap it to the
|
|
52
|
+
* detent it happens to be nearest. That is what every native sheet does, and
|
|
53
|
+
* getting it backwards makes the sheet feel like it is fighting you.
|
|
54
|
+
*/
|
|
55
|
+
export declare function settleTo({ current, detents, velocity }: SettleInput): number | null;
|
|
56
|
+
export interface SheetGestureOptions {
|
|
57
|
+
detents: number[];
|
|
58
|
+
initialDetent?: number;
|
|
59
|
+
onDismiss: () => void;
|
|
60
|
+
/** Skips the drag entirely; the sheet still opens and closes, just without motion. */
|
|
61
|
+
reducedMotion?: boolean;
|
|
62
|
+
}
|
|
63
|
+
export interface SheetGesture {
|
|
64
|
+
/** Current height as a fraction of the viewport. */
|
|
65
|
+
height: number;
|
|
66
|
+
/** True while a finger is down — the component uses this to drop its transition. */
|
|
67
|
+
dragging: boolean;
|
|
68
|
+
/** True when the sheet is at its tallest detent. */
|
|
69
|
+
expanded: boolean;
|
|
70
|
+
/** Attach to the grabber and header. */
|
|
71
|
+
onPointerDown: (e: React.PointerEvent) => void;
|
|
72
|
+
/**
|
|
73
|
+
* Attach to the scrollable body. Implements the behaviour the pattern is
|
|
74
|
+
* named for: at a partial detent, dragging up grows the sheet instead of
|
|
75
|
+
* scrolling; once expanded, the content scrolls normally; and at the top of
|
|
76
|
+
* the content, dragging down shrinks the sheet again.
|
|
77
|
+
*/
|
|
78
|
+
onBodyPointerDown: (e: React.PointerEvent) => void;
|
|
79
|
+
setHeight: (h: number) => void;
|
|
80
|
+
}
|
|
81
|
+
export declare function useSheetGesture({ detents, initialDetent, onDismiss, reducedMotion, }: SheetGestureOptions): SheetGesture;
|