@otfdashkit/ui-native 0.1.1 → 0.1.3
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 +1 -1
- package/dist/index.d.ts +13 -0
- package/dist/index.js +323 -110
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +231 -14
- package/dist/index.mjs.map +1 -1
- package/dist/skia.d.ts +14 -0
- package/dist/skia.js +317 -0
- package/dist/skia.js.map +1 -0
- package/dist/skia.mjs +310 -0
- package/dist/skia.mjs.map +1 -0
- package/package.json +19 -5
package/LICENSE
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -307,3 +307,16 @@ export type CardScrollerProps<T = unknown> = {
|
|
|
307
307
|
export const useCollapsibleHeader: any
|
|
308
308
|
export type UseCollapsibleHeaderOptions = any
|
|
309
309
|
export type UseCollapsibleHeaderReturn = any
|
|
310
|
+
|
|
311
|
+
// ─── Shockwave moved to `@otfdashkit/ui-native/skia` subpath ──────────────
|
|
312
|
+
// See `packages/ui-native/types/skia.d.ts` for the type stubs and the
|
|
313
|
+
// "Why subpath exports?" section in `docs/sdk-design.md`.
|
|
314
|
+
|
|
315
|
+
// ─── Stay (real-estate / booking marketing screens) ───────────────────────
|
|
316
|
+
export const StayBrowseScreen: any
|
|
317
|
+
export const StayDetailScreen: any
|
|
318
|
+
export type StayBrowseScreenProps = any
|
|
319
|
+
export type StayCategoryChip = any
|
|
320
|
+
export type StayDetailMetric = any
|
|
321
|
+
export type StayDetailScreenProps = any
|
|
322
|
+
export type StayListing = any
|
package/dist/index.js
CHANGED
|
@@ -29,79 +29,79 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
29
29
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
30
30
|
|
|
31
31
|
// src/index.ts
|
|
32
|
-
var
|
|
33
|
-
__export(
|
|
34
|
-
Accordion: () =>
|
|
32
|
+
var src_exports = {};
|
|
33
|
+
__export(src_exports, {
|
|
34
|
+
Accordion: () => import_tamagui78.Accordion,
|
|
35
35
|
ActionSheet: () => ActionSheet,
|
|
36
|
-
Adapt: () =>
|
|
37
|
-
AlertDialog: () =>
|
|
38
|
-
Anchor: () =>
|
|
39
|
-
AnimatePresence: () =>
|
|
36
|
+
Adapt: () => import_tamagui78.Adapt,
|
|
37
|
+
AlertDialog: () => import_tamagui78.AlertDialog,
|
|
38
|
+
Anchor: () => import_tamagui78.Anchor,
|
|
39
|
+
AnimatePresence: () => import_tamagui78.AnimatePresence,
|
|
40
40
|
AnimatedView: () => AnimatedView,
|
|
41
41
|
AppHeader: () => AppHeader,
|
|
42
42
|
AppleLogo: () => AppleLogo,
|
|
43
|
-
Article: () =>
|
|
44
|
-
Aside: () =>
|
|
45
|
-
Avatar: () =>
|
|
43
|
+
Article: () => import_tamagui78.Article,
|
|
44
|
+
Aside: () => import_tamagui78.Aside,
|
|
45
|
+
Avatar: () => import_tamagui78.Avatar,
|
|
46
46
|
AvatarGroup: () => AvatarGroup,
|
|
47
47
|
Badge: () => Badge,
|
|
48
48
|
BottomSheet: () => BottomSheet,
|
|
49
|
-
Button: () =>
|
|
50
|
-
Card: () =>
|
|
49
|
+
Button: () => import_tamagui78.Button,
|
|
50
|
+
Card: () => import_tamagui78.Card,
|
|
51
51
|
CardScroller: () => CardScroller,
|
|
52
52
|
Carousel: () => Carousel,
|
|
53
53
|
ChatBubble: () => ChatBubble,
|
|
54
|
-
Checkbox: () =>
|
|
54
|
+
Checkbox: () => import_tamagui78.Checkbox,
|
|
55
55
|
Chip: () => Chip,
|
|
56
56
|
ChipGroup: () => ChipGroup,
|
|
57
57
|
ChipsTabBar: () => ChipsTabBar,
|
|
58
|
-
Circle: () =>
|
|
58
|
+
Circle: () => import_tamagui78.Circle,
|
|
59
59
|
ConfirmDialog: () => ConfirmDialog,
|
|
60
60
|
Container: () => Container,
|
|
61
61
|
CountdownBanner: () => CountdownBanner,
|
|
62
62
|
DataTable: () => DataTable,
|
|
63
63
|
DatePicker: () => DatePicker,
|
|
64
|
-
Dialog: () =>
|
|
64
|
+
Dialog: () => import_tamagui78.Dialog,
|
|
65
65
|
DialogProvider: () => DialogProvider,
|
|
66
66
|
Divider: () => Divider,
|
|
67
67
|
EmptyState: () => EmptyState,
|
|
68
|
-
EnsureFlexed: () =>
|
|
68
|
+
EnsureFlexed: () => import_tamagui78.EnsureFlexed,
|
|
69
69
|
EventCard: () => EventCard,
|
|
70
70
|
Expandable: () => Expandable,
|
|
71
|
-
Fieldset: () =>
|
|
71
|
+
Fieldset: () => import_tamagui78.Fieldset,
|
|
72
72
|
FinanceDashboard: () => FinanceDashboard,
|
|
73
73
|
FloatingActionButton: () => FloatingActionButton,
|
|
74
|
-
Footer: () =>
|
|
75
|
-
Form: () =>
|
|
74
|
+
Footer: () => import_tamagui78.Footer,
|
|
75
|
+
Form: () => import_tamagui78.Form,
|
|
76
76
|
FormField: () => FormField,
|
|
77
|
-
Frame: () =>
|
|
77
|
+
Frame: () => import_tamagui78.Frame,
|
|
78
78
|
GitHubLogo: () => GitHubLogo,
|
|
79
79
|
GlassCard: () => GlassCard,
|
|
80
80
|
GoogleLogo: () => GoogleLogo,
|
|
81
81
|
Grid: () => Grid,
|
|
82
|
-
Group: () =>
|
|
83
|
-
H1: () =>
|
|
84
|
-
H2: () =>
|
|
85
|
-
H3: () =>
|
|
86
|
-
H4: () =>
|
|
87
|
-
H5: () =>
|
|
88
|
-
H6: () =>
|
|
89
|
-
Header: () =>
|
|
90
|
-
Heading: () =>
|
|
82
|
+
Group: () => import_tamagui78.Group,
|
|
83
|
+
H1: () => import_tamagui78.H1,
|
|
84
|
+
H2: () => import_tamagui78.H2,
|
|
85
|
+
H3: () => import_tamagui78.H3,
|
|
86
|
+
H4: () => import_tamagui78.H4,
|
|
87
|
+
H5: () => import_tamagui78.H5,
|
|
88
|
+
H6: () => import_tamagui78.H6,
|
|
89
|
+
Header: () => import_tamagui78.Header,
|
|
90
|
+
Heading: () => import_tamagui78.Heading,
|
|
91
91
|
ICONS: () => ICONS,
|
|
92
92
|
Icon: () => Icon,
|
|
93
93
|
Image: () => import_tamagui11.Image,
|
|
94
94
|
ImmersiveMediaScreen: () => ImmersiveMediaScreen,
|
|
95
|
-
Input: () =>
|
|
95
|
+
Input: () => import_tamagui78.Input,
|
|
96
96
|
KeyboardStickyFooter: () => KeyboardStickyFooter,
|
|
97
|
-
Label: () =>
|
|
97
|
+
Label: () => import_tamagui78.Label,
|
|
98
98
|
ListItem: () => ListItem,
|
|
99
99
|
LoginScreen: () => LoginScreen,
|
|
100
|
-
Main: () =>
|
|
100
|
+
Main: () => import_tamagui78.Main,
|
|
101
101
|
MediaCard: () => MediaCard,
|
|
102
102
|
MicrosoftLogo: () => MicrosoftLogo,
|
|
103
103
|
MultiStep: () => MultiStep,
|
|
104
|
-
Nav: () =>
|
|
104
|
+
Nav: () => import_tamagui78.Nav,
|
|
105
105
|
NotificationBanner: () => NotificationBanner,
|
|
106
106
|
OTF_DESIGN_THEMES: () => OTF_DESIGN_THEMES,
|
|
107
107
|
OTF_DESIGN_THEME_IDS: () => OTF_DESIGN_THEME_IDS,
|
|
@@ -114,7 +114,7 @@ __export(index_exports, {
|
|
|
114
114
|
OtfDialog: () => OtfDialog,
|
|
115
115
|
OtfInput: () => Input,
|
|
116
116
|
OtfPopover: () => OtfPopover,
|
|
117
|
-
OtfProvider: () =>
|
|
117
|
+
OtfProvider: () => import_tamagui78.TamaguiProvider,
|
|
118
118
|
OtfSelect: () => OtfSelect,
|
|
119
119
|
OtfTabs: () => OtfTabs,
|
|
120
120
|
OtfText: () => OtfText,
|
|
@@ -123,119 +123,121 @@ __export(index_exports, {
|
|
|
123
123
|
OtfTooltip: () => OtfTooltip,
|
|
124
124
|
PageContainer: () => PageContainer,
|
|
125
125
|
PageMainContainer: () => PageMainContainer,
|
|
126
|
-
Paragraph: () =>
|
|
126
|
+
Paragraph: () => import_tamagui78.Paragraph,
|
|
127
127
|
PasswordInput: () => PasswordInput,
|
|
128
128
|
PaywallScreen: () => PaywallScreen,
|
|
129
|
-
Popover: () =>
|
|
130
|
-
Portal: () =>
|
|
131
|
-
PortalHost: () =>
|
|
132
|
-
PortalItem: () =>
|
|
133
|
-
PortalProvider: () =>
|
|
129
|
+
Popover: () => import_tamagui78.Popover,
|
|
130
|
+
Portal: () => import_tamagui78.Portal,
|
|
131
|
+
PortalHost: () => import_tamagui78.PortalHost,
|
|
132
|
+
PortalItem: () => import_tamagui78.PortalItem,
|
|
133
|
+
PortalProvider: () => import_tamagui78.PortalProvider,
|
|
134
134
|
Pressable: () => Pressable,
|
|
135
135
|
PricingTable: () => PricingTable,
|
|
136
136
|
ProductCard: () => ProductCard,
|
|
137
137
|
ProfileHeader: () => ProfileHeader,
|
|
138
|
-
Progress: () =>
|
|
138
|
+
Progress: () => import_tamagui78.Progress,
|
|
139
139
|
ProgressSteps: () => ProgressSteps,
|
|
140
140
|
PullToRefresh: () => PullToRefresh,
|
|
141
|
-
RadioGroup: () =>
|
|
141
|
+
RadioGroup: () => import_tamagui78.RadioGroup,
|
|
142
142
|
RulerScrubber: () => RulerScrubber,
|
|
143
143
|
SafeArea: () => SafeArea,
|
|
144
144
|
ScreenLayout: () => ScreenLayout,
|
|
145
|
-
ScrollView: () =>
|
|
145
|
+
ScrollView: () => import_tamagui78.ScrollView,
|
|
146
146
|
SearchBar: () => SearchBar,
|
|
147
147
|
Section: () => Section,
|
|
148
|
-
Select: () =>
|
|
148
|
+
Select: () => import_tamagui78.Select,
|
|
149
149
|
Selectable: () => Selectable,
|
|
150
150
|
SelectableGroup: () => SelectableGroup,
|
|
151
151
|
SepHeading: () => SepHeading,
|
|
152
|
-
Separator: () =>
|
|
152
|
+
Separator: () => import_tamagui78.Separator,
|
|
153
153
|
SettingsScreen: () => SettingsScreen,
|
|
154
|
-
Sheet: () =>
|
|
155
|
-
SizableStack: () =>
|
|
156
|
-
SizableText: () =>
|
|
154
|
+
Sheet: () => import_tamagui78.Sheet,
|
|
155
|
+
SizableStack: () => import_tamagui78.SizableStack,
|
|
156
|
+
SizableText: () => import_tamagui78.SizableText,
|
|
157
157
|
Skeleton: () => Skeleton,
|
|
158
|
-
Slider: () =>
|
|
159
|
-
Spacer: () =>
|
|
160
|
-
Spinner: () =>
|
|
161
|
-
Square: () =>
|
|
162
|
-
Stack: () =>
|
|
158
|
+
Slider: () => import_tamagui78.Slider,
|
|
159
|
+
Spacer: () => import_tamagui78.Spacer,
|
|
160
|
+
Spinner: () => import_tamagui78.Spinner,
|
|
161
|
+
Square: () => import_tamagui78.Square,
|
|
162
|
+
Stack: () => import_tamagui78.Stack,
|
|
163
163
|
StatusBadge: () => StatusBadge,
|
|
164
|
+
StayBrowseScreen: () => StayBrowseScreen,
|
|
165
|
+
StayDetailScreen: () => StayDetailScreen,
|
|
164
166
|
Step: () => Step,
|
|
165
167
|
StepPageLayout: () => StepPageLayout,
|
|
166
168
|
SubHeading: () => SubHeading,
|
|
167
169
|
SwipeCards: () => SwipeCards,
|
|
168
170
|
SwipeableRow: () => SwipeableRow,
|
|
169
|
-
Switch: () =>
|
|
171
|
+
Switch: () => import_tamagui78.Switch,
|
|
170
172
|
TabBar: () => TabBar,
|
|
171
|
-
Tabs: () =>
|
|
172
|
-
TamaguiImage: () =>
|
|
173
|
-
TamaguiListItem: () =>
|
|
174
|
-
TamaguiProvider: () =>
|
|
173
|
+
Tabs: () => import_tamagui78.Tabs,
|
|
174
|
+
TamaguiImage: () => import_tamagui78.Image,
|
|
175
|
+
TamaguiListItem: () => import_tamagui78.ListItem,
|
|
176
|
+
TamaguiProvider: () => import_tamagui78.TamaguiProvider,
|
|
175
177
|
TestimonialCard: () => TestimonialCard2,
|
|
176
|
-
Text: () =>
|
|
177
|
-
TextArea: () =>
|
|
178
|
-
Theme: () =>
|
|
179
|
-
ThemeableStack: () =>
|
|
180
|
-
ToggleGroup: () =>
|
|
181
|
-
Tooltip: () =>
|
|
182
|
-
TooltipSimple: () =>
|
|
183
|
-
Unspaced: () =>
|
|
178
|
+
Text: () => import_tamagui78.Text,
|
|
179
|
+
TextArea: () => import_tamagui78.TextArea,
|
|
180
|
+
Theme: () => import_tamagui78.Theme,
|
|
181
|
+
ThemeableStack: () => import_tamagui78.ThemeableStack,
|
|
182
|
+
ToggleGroup: () => import_tamagui78.ToggleGroup,
|
|
183
|
+
Tooltip: () => import_tamagui78.Tooltip,
|
|
184
|
+
TooltipSimple: () => import_tamagui78.TooltipSimple,
|
|
185
|
+
Unspaced: () => import_tamagui78.Unspaced,
|
|
184
186
|
UserPreferences: () => UserPreferences,
|
|
185
|
-
View: () =>
|
|
186
|
-
VisuallyHidden: () =>
|
|
187
|
+
View: () => import_tamagui78.View,
|
|
188
|
+
VisuallyHidden: () => import_tamagui78.VisuallyHidden,
|
|
187
189
|
WheelPicker: () => WheelPicker,
|
|
188
|
-
XGroup: () =>
|
|
189
|
-
XStack: () =>
|
|
190
|
-
YGroup: () =>
|
|
191
|
-
YStack: () =>
|
|
192
|
-
ZStack: () =>
|
|
193
|
-
addTheme: () =>
|
|
194
|
-
composeEventHandlers: () =>
|
|
195
|
-
composeRefs: () =>
|
|
196
|
-
createFont: () =>
|
|
197
|
-
createMedia: () =>
|
|
198
|
-
createStyledContext: () =>
|
|
199
|
-
createTamagui: () =>
|
|
200
|
-
createTheme: () =>
|
|
201
|
-
createTokens: () =>
|
|
202
|
-
createVariable: () =>
|
|
190
|
+
XGroup: () => import_tamagui78.XGroup,
|
|
191
|
+
XStack: () => import_tamagui78.XStack,
|
|
192
|
+
YGroup: () => import_tamagui78.YGroup,
|
|
193
|
+
YStack: () => import_tamagui78.YStack,
|
|
194
|
+
ZStack: () => import_tamagui78.ZStack,
|
|
195
|
+
addTheme: () => import_tamagui78.addTheme,
|
|
196
|
+
composeEventHandlers: () => import_tamagui78.composeEventHandlers,
|
|
197
|
+
composeRefs: () => import_tamagui78.composeRefs,
|
|
198
|
+
createFont: () => import_tamagui78.createFont,
|
|
199
|
+
createMedia: () => import_tamagui78.createMedia,
|
|
200
|
+
createStyledContext: () => import_tamagui78.createStyledContext,
|
|
201
|
+
createTamagui: () => import_tamagui78.createTamagui,
|
|
202
|
+
createTheme: () => import_tamagui78.createTheme,
|
|
203
|
+
createTokens: () => import_tamagui78.createTokens,
|
|
204
|
+
createVariable: () => import_tamagui78.createVariable,
|
|
203
205
|
dialogConfirm: () => dialogConfirm,
|
|
204
|
-
getConfig: () =>
|
|
206
|
+
getConfig: () => import_tamagui78.getConfig,
|
|
205
207
|
getOtfDesignTheme: () => getOtfDesignTheme,
|
|
206
208
|
getOtfThemePalettes: () => getOtfThemePalettes,
|
|
207
|
-
getToken: () =>
|
|
208
|
-
getTokenValue: () =>
|
|
209
|
-
getTokens: () =>
|
|
210
|
-
isClient: () =>
|
|
211
|
-
isWeb: () =>
|
|
209
|
+
getToken: () => import_tamagui78.getToken,
|
|
210
|
+
getTokenValue: () => import_tamagui78.getTokenValue,
|
|
211
|
+
getTokens: () => import_tamagui78.getTokens,
|
|
212
|
+
isClient: () => import_tamagui78.isClient,
|
|
213
|
+
isWeb: () => import_tamagui78.isWeb,
|
|
212
214
|
otfConfig: () => otfConfig,
|
|
213
|
-
replaceTheme: () =>
|
|
215
|
+
replaceTheme: () => import_tamagui78.replaceTheme,
|
|
214
216
|
showError: () => showError,
|
|
215
|
-
styled: () =>
|
|
217
|
+
styled: () => import_tamagui78.styled,
|
|
216
218
|
tamaguiDefaultConfig: () => import_v52.defaultConfig,
|
|
217
219
|
toast: () => toast,
|
|
218
|
-
updateTheme: () =>
|
|
220
|
+
updateTheme: () => import_tamagui78.updateTheme,
|
|
219
221
|
useCollapsibleHeader: () => useCollapsibleHeader,
|
|
220
|
-
useComposedRefs: () =>
|
|
221
|
-
useControllableState: () =>
|
|
222
|
-
useDebounce: () =>
|
|
223
|
-
useDebounceValue: () =>
|
|
224
|
-
useDidFinishSSR: () =>
|
|
225
|
-
useEvent: () =>
|
|
226
|
-
useForceUpdate: () =>
|
|
227
|
-
useIsPresent: () =>
|
|
228
|
-
useIsomorphicLayoutEffect: () =>
|
|
229
|
-
useMedia: () =>
|
|
222
|
+
useComposedRefs: () => import_tamagui78.useComposedRefs,
|
|
223
|
+
useControllableState: () => import_tamagui78.useControllableState,
|
|
224
|
+
useDebounce: () => import_tamagui78.useDebounce,
|
|
225
|
+
useDebounceValue: () => import_tamagui78.useDebounceValue,
|
|
226
|
+
useDidFinishSSR: () => import_tamagui78.useDidFinishSSR,
|
|
227
|
+
useEvent: () => import_tamagui78.useEvent,
|
|
228
|
+
useForceUpdate: () => import_tamagui78.useForceUpdate,
|
|
229
|
+
useIsPresent: () => import_tamagui78.useIsPresent,
|
|
230
|
+
useIsomorphicLayoutEffect: () => import_tamagui78.useIsomorphicLayoutEffect,
|
|
231
|
+
useMedia: () => import_tamagui78.useMedia,
|
|
230
232
|
useMultiStep: () => useMultiStep,
|
|
231
233
|
useOtfToast: () => useOtfToast,
|
|
232
|
-
usePresence: () =>
|
|
233
|
-
useTheme: () =>
|
|
234
|
-
useThemeName: () =>
|
|
235
|
-
useWindowDimensions: () =>
|
|
236
|
-
withStaticProperties: () =>
|
|
234
|
+
usePresence: () => import_tamagui78.usePresence,
|
|
235
|
+
useTheme: () => import_tamagui78.useTheme,
|
|
236
|
+
useThemeName: () => import_tamagui78.useThemeName,
|
|
237
|
+
useWindowDimensions: () => import_tamagui78.useWindowDimensions,
|
|
238
|
+
withStaticProperties: () => import_tamagui78.withStaticProperties
|
|
237
239
|
});
|
|
238
|
-
module.exports = __toCommonJS(
|
|
240
|
+
module.exports = __toCommonJS(src_exports);
|
|
239
241
|
|
|
240
242
|
// src/config/tamagui.config.ts
|
|
241
243
|
var import_v5 = require("@tamagui/config/v5");
|
|
@@ -417,7 +419,7 @@ function getOtfDesignTheme(themeId) {
|
|
|
417
419
|
}
|
|
418
420
|
|
|
419
421
|
// src/index.ts
|
|
420
|
-
var
|
|
422
|
+
var import_tamagui78 = require("tamagui");
|
|
421
423
|
|
|
422
424
|
// src/primitives/Button.tsx
|
|
423
425
|
var import_tamagui2 = require("tamagui");
|
|
@@ -4230,7 +4232,7 @@ function OtfPopover({
|
|
|
4230
4232
|
}
|
|
4231
4233
|
|
|
4232
4234
|
// src/index.ts
|
|
4233
|
-
__reExport(
|
|
4235
|
+
__reExport(src_exports, require("@tamagui/lucide-icons"), module.exports);
|
|
4234
4236
|
|
|
4235
4237
|
// src/patterns/ImmersiveMediaScreen.tsx
|
|
4236
4238
|
var import_tamagui67 = require("tamagui");
|
|
@@ -5907,6 +5909,215 @@ function useCollapsibleHeader(opts = {}) {
|
|
|
5907
5909
|
});
|
|
5908
5910
|
return { scrollHandler, headerStyle, titleStyle, scrollY };
|
|
5909
5911
|
}
|
|
5912
|
+
|
|
5913
|
+
// src/patterns/StayCard/StayBrowseScreen.tsx
|
|
5914
|
+
var import_react_native13 = require("react-native");
|
|
5915
|
+
var import_tamagui75 = require("tamagui");
|
|
5916
|
+
var import_lucide_icons4 = require("@tamagui/lucide-icons");
|
|
5917
|
+
var import_jsx_runtime69 = require("react/jsx-runtime");
|
|
5918
|
+
var DEFAULT_CATEGORIES = [
|
|
5919
|
+
{ label: "Villa" },
|
|
5920
|
+
{ label: "Hotel", active: true },
|
|
5921
|
+
{ label: "Apartment" },
|
|
5922
|
+
{ label: "Campsite" }
|
|
5923
|
+
];
|
|
5924
|
+
function StayBrowseScreen({
|
|
5925
|
+
greeting = "Good morning",
|
|
5926
|
+
headline = "Unlock Your\nPerfect Stay Today!",
|
|
5927
|
+
categories = DEFAULT_CATEGORIES,
|
|
5928
|
+
listing,
|
|
5929
|
+
onFavorite,
|
|
5930
|
+
backgroundColor = "#fafaf9"
|
|
5931
|
+
}) {
|
|
5932
|
+
return /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_tamagui75.YStack, { flex: 1, backgroundColor, padding: 18, gap: 14, children: [
|
|
5933
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_tamagui75.YStack, { gap: 4, marginTop: 28, children: [
|
|
5934
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_tamagui75.SizableText, { size: "$2", color: "#737373", children: greeting }),
|
|
5935
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_tamagui75.H3, { color: "#0a0a0a", size: "$7", lineHeight: 28, children: headline })
|
|
5936
|
+
] }),
|
|
5937
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_tamagui75.XStack, { gap: 8, flexWrap: "wrap", children: categories.map((c) => /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
5938
|
+
import_react_native13.View,
|
|
5939
|
+
{
|
|
5940
|
+
onTouchEnd: c.onPress,
|
|
5941
|
+
style: {
|
|
5942
|
+
paddingHorizontal: 12,
|
|
5943
|
+
paddingVertical: 6,
|
|
5944
|
+
borderRadius: 999,
|
|
5945
|
+
backgroundColor: c.active ? "#d9f99d" : "#f4f4f5"
|
|
5946
|
+
},
|
|
5947
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
5948
|
+
import_tamagui75.SizableText,
|
|
5949
|
+
{
|
|
5950
|
+
size: "$2",
|
|
5951
|
+
color: c.active ? "#365314" : "#52525b",
|
|
5952
|
+
fontWeight: "600",
|
|
5953
|
+
children: c.label
|
|
5954
|
+
}
|
|
5955
|
+
)
|
|
5956
|
+
},
|
|
5957
|
+
c.label
|
|
5958
|
+
)) }),
|
|
5959
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(
|
|
5960
|
+
import_tamagui75.YStack,
|
|
5961
|
+
{
|
|
5962
|
+
flex: 1,
|
|
5963
|
+
borderRadius: 20,
|
|
5964
|
+
overflow: "hidden",
|
|
5965
|
+
backgroundColor: "#e7e5e4",
|
|
5966
|
+
marginTop: 4,
|
|
5967
|
+
children: [
|
|
5968
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
5969
|
+
import_react_native13.Image,
|
|
5970
|
+
{
|
|
5971
|
+
source: { uri: listing.image },
|
|
5972
|
+
style: { width: "100%", height: "60%" },
|
|
5973
|
+
resizeMode: "cover"
|
|
5974
|
+
}
|
|
5975
|
+
),
|
|
5976
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_tamagui75.YStack, { flex: 1, padding: 14, gap: 8, children: [
|
|
5977
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_tamagui75.XStack, { alignItems: "center", justifyContent: "space-between", children: [
|
|
5978
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_tamagui75.H4, { color: "#0a0a0a", size: "$5", children: listing.title }),
|
|
5979
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_react_native13.View, { onTouchEnd: onFavorite, children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_lucide_icons4.Heart, { size: 18, color: "#ef4444" }) })
|
|
5980
|
+
] }),
|
|
5981
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_tamagui75.XStack, { alignItems: "center", gap: 4, children: [
|
|
5982
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_lucide_icons4.MapPin, { size: 12, color: "#737373" }),
|
|
5983
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_tamagui75.SizableText, { size: "$1", color: "#737373", children: listing.address })
|
|
5984
|
+
] }),
|
|
5985
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_tamagui75.XStack, { gap: 14, marginTop: 6, children: [
|
|
5986
|
+
typeof listing.bed === "number" ? /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_tamagui75.XStack, { alignItems: "center", gap: 4, children: [
|
|
5987
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_lucide_icons4.Bed, { size: 14, color: "#737373" }),
|
|
5988
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_tamagui75.SizableText, { size: "$1", color: "#525252", children: [
|
|
5989
|
+
"Bed: ",
|
|
5990
|
+
listing.bed
|
|
5991
|
+
] })
|
|
5992
|
+
] }) : null,
|
|
5993
|
+
typeof listing.bath === "number" ? /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_tamagui75.XStack, { alignItems: "center", gap: 4, children: [
|
|
5994
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_lucide_icons4.Bath, { size: 14, color: "#737373" }),
|
|
5995
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_tamagui75.SizableText, { size: "$1", color: "#525252", children: [
|
|
5996
|
+
"Bath: ",
|
|
5997
|
+
listing.bath
|
|
5998
|
+
] })
|
|
5999
|
+
] }) : null,
|
|
6000
|
+
typeof listing.rating === "number" ? /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_tamagui75.XStack, { alignItems: "center", gap: 4, children: [
|
|
6001
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_lucide_icons4.Star, { size: 14, color: "#f59e0b", fill: "#f59e0b" }),
|
|
6002
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(import_tamagui75.SizableText, { size: "$1", color: "#525252", children: listing.rating.toFixed(1) })
|
|
6003
|
+
] }) : null
|
|
6004
|
+
] })
|
|
6005
|
+
] })
|
|
6006
|
+
]
|
|
6007
|
+
}
|
|
6008
|
+
)
|
|
6009
|
+
] });
|
|
6010
|
+
}
|
|
6011
|
+
|
|
6012
|
+
// src/patterns/StayCard/StayDetailScreen.tsx
|
|
6013
|
+
var import_react_native14 = require("react-native");
|
|
6014
|
+
var import_tamagui76 = require("tamagui");
|
|
6015
|
+
var import_lucide_icons5 = require("@tamagui/lucide-icons");
|
|
6016
|
+
var import_jsx_runtime70 = require("react/jsx-runtime");
|
|
6017
|
+
var formatPrice = (n) => "$" + n.toLocaleString("en-US", { maximumFractionDigits: 0 });
|
|
6018
|
+
var buildDefaultMetrics = (props) => {
|
|
6019
|
+
const out = [];
|
|
6020
|
+
if (typeof props.listing.sqft === "number") {
|
|
6021
|
+
out.push({
|
|
6022
|
+
label: "Living",
|
|
6023
|
+
value: `${props.listing.sqft} sqft`
|
|
6024
|
+
});
|
|
6025
|
+
} else if (typeof props.listing.bed === "number") {
|
|
6026
|
+
out.push({
|
|
6027
|
+
label: "Beds",
|
|
6028
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_lucide_icons5.Bed, { size: 14, color: "#fafaf9" }),
|
|
6029
|
+
value: props.listing.bed
|
|
6030
|
+
});
|
|
6031
|
+
}
|
|
6032
|
+
if (typeof props.listing.bath === "number") {
|
|
6033
|
+
out.push({
|
|
6034
|
+
label: "Baths",
|
|
6035
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_lucide_icons5.Bath, { size: 14, color: "#fafaf9" }),
|
|
6036
|
+
value: props.listing.bath
|
|
6037
|
+
});
|
|
6038
|
+
}
|
|
6039
|
+
out.push({
|
|
6040
|
+
label: "Wifi",
|
|
6041
|
+
icon: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_lucide_icons5.Wifi, { size: 14, color: "#fafaf9" }),
|
|
6042
|
+
value: "Fast"
|
|
6043
|
+
});
|
|
6044
|
+
return out;
|
|
6045
|
+
};
|
|
6046
|
+
function StayDetailScreen(props) {
|
|
6047
|
+
const {
|
|
6048
|
+
listing,
|
|
6049
|
+
metrics,
|
|
6050
|
+
eyebrow = "BOOKING DETAILS",
|
|
6051
|
+
ctaLabel = "Reserve now",
|
|
6052
|
+
onReserve,
|
|
6053
|
+
backgroundColor = "#0a0a0a",
|
|
6054
|
+
ctaColor = "#f97316"
|
|
6055
|
+
} = props;
|
|
6056
|
+
const resolvedMetrics = metrics ?? buildDefaultMetrics(props);
|
|
6057
|
+
return /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_tamagui76.YStack, { flex: 1, backgroundColor, children: [
|
|
6058
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_react_native14.View, { style: { position: "relative", height: "50%" }, children: [
|
|
6059
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
|
|
6060
|
+
import_react_native14.Image,
|
|
6061
|
+
{
|
|
6062
|
+
source: { uri: listing.image },
|
|
6063
|
+
style: { width: "100%", height: "100%" },
|
|
6064
|
+
resizeMode: "cover"
|
|
6065
|
+
}
|
|
6066
|
+
),
|
|
6067
|
+
typeof listing.rating === "number" ? /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(
|
|
6068
|
+
import_react_native14.View,
|
|
6069
|
+
{
|
|
6070
|
+
style: {
|
|
6071
|
+
position: "absolute",
|
|
6072
|
+
top: 36,
|
|
6073
|
+
right: 18,
|
|
6074
|
+
backgroundColor: "rgba(255,255,255,0.92)",
|
|
6075
|
+
paddingHorizontal: 10,
|
|
6076
|
+
paddingVertical: 6,
|
|
6077
|
+
borderRadius: 999,
|
|
6078
|
+
flexDirection: "row",
|
|
6079
|
+
alignItems: "center",
|
|
6080
|
+
gap: 4
|
|
6081
|
+
},
|
|
6082
|
+
children: [
|
|
6083
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_lucide_icons5.Star, { size: 12, color: "#f59e0b", fill: "#f59e0b" }),
|
|
6084
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_tamagui76.SizableText, { size: "$1", color: "#0a0a0a", fontWeight: "700", children: listing.rating.toFixed(1) })
|
|
6085
|
+
]
|
|
6086
|
+
}
|
|
6087
|
+
) : null
|
|
6088
|
+
] }),
|
|
6089
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_tamagui76.YStack, { flex: 1, padding: 18, gap: 10, children: [
|
|
6090
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_tamagui76.SizableText, { size: "$2", color: "#a3a3a3", children: eyebrow }),
|
|
6091
|
+
typeof listing.pricePerNight === "number" ? /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_tamagui76.H3, { color: "#fafaf9", size: "$7", children: [
|
|
6092
|
+
formatPrice(listing.pricePerNight),
|
|
6093
|
+
"/night"
|
|
6094
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_tamagui76.H3, { color: "#fafaf9", size: "$7", children: listing.title }),
|
|
6095
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_tamagui76.SizableText, { size: "$2", color: "#a3a3a3", children: [
|
|
6096
|
+
listing.ownerName ? listing.ownerName + " \xB7 " : "",
|
|
6097
|
+
listing.address
|
|
6098
|
+
] }),
|
|
6099
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_tamagui76.XStack, { gap: 20, marginTop: 6, children: resolvedMetrics.map((m, i) => /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_tamagui76.YStack, { gap: 2, children: [
|
|
6100
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_tamagui76.SizableText, { size: "$1", color: "#737373", children: m.label }),
|
|
6101
|
+
m.icon ? /* @__PURE__ */ (0, import_jsx_runtime70.jsxs)(import_tamagui76.XStack, { alignItems: "center", gap: 4, children: [
|
|
6102
|
+
m.icon,
|
|
6103
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_tamagui76.SizableText, { size: "$3", color: "#fafaf9", fontWeight: "600", children: m.value })
|
|
6104
|
+
] }) : /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_tamagui76.SizableText, { size: "$3", color: "#fafaf9", fontWeight: "600", children: m.value })
|
|
6105
|
+
] }, i)) }),
|
|
6106
|
+
/* @__PURE__ */ (0, import_jsx_runtime70.jsx)(
|
|
6107
|
+
import_tamagui76.YStack,
|
|
6108
|
+
{
|
|
6109
|
+
marginTop: "auto",
|
|
6110
|
+
padding: 14,
|
|
6111
|
+
borderRadius: 14,
|
|
6112
|
+
backgroundColor: ctaColor,
|
|
6113
|
+
alignItems: "center",
|
|
6114
|
+
onPress: onReserve,
|
|
6115
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime70.jsx)(import_tamagui76.SizableText, { size: "$3", color: "#fff", fontWeight: "700", children: ctaLabel })
|
|
6116
|
+
}
|
|
6117
|
+
)
|
|
6118
|
+
] })
|
|
6119
|
+
] });
|
|
6120
|
+
}
|
|
5910
6121
|
// Annotate the CommonJS export names for ESM import in node:
|
|
5911
6122
|
0 && (module.exports = {
|
|
5912
6123
|
Accordion,
|
|
@@ -6039,6 +6250,8 @@ function useCollapsibleHeader(opts = {}) {
|
|
|
6039
6250
|
Square,
|
|
6040
6251
|
Stack,
|
|
6041
6252
|
StatusBadge,
|
|
6253
|
+
StayBrowseScreen,
|
|
6254
|
+
StayDetailScreen,
|
|
6042
6255
|
Step,
|
|
6043
6256
|
StepPageLayout,
|
|
6044
6257
|
SubHeading,
|