@tachui/core 0.7.1-alpha → 0.8.0-alpha
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 +2 -2
- package/dist/bundles/common.d.ts +1 -1
- package/dist/bundles/common.d.ts.map +1 -1
- package/dist/bundles/minimal.d.ts +2 -16
- package/dist/bundles/minimal.d.ts.map +1 -1
- package/dist/bundles/production-minimal.d.ts +2 -16
- package/dist/bundles/production-minimal.d.ts.map +1 -1
- package/dist/common.js +403 -827
- package/dist/compiler/advanced-parser.d.ts.map +1 -1
- package/dist/compiler/index.js +14 -8
- package/dist/component-XAzF1xqs.js +487 -0
- package/dist/component-base-x2XmHFjy.js +255 -0
- package/dist/components/index.d.ts +4 -38
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/index.js +7 -4167
- package/dist/components/wrapper.d.ts +5 -152
- package/dist/components/wrapper.d.ts.map +1 -1
- package/dist/concatenated-component-ByPl3_FF.js +2933 -0
- package/dist/constants/index.d.ts +1 -1
- package/dist/constants/layout.d.ts +47 -4
- package/dist/constants/layout.d.ts.map +1 -1
- package/dist/constants/layout.js +84 -0
- package/dist/css-classes/index.js +176 -0
- package/dist/{dom-bridge-Cx-s6Ihx.js → dom-bridge-CAa1N2zX.js} +28 -28
- package/dist/{effect-CytAc9em.js → effect-B9Knft0b.js} +3 -3
- package/dist/essential.js +395 -825
- package/dist/index-DCPJFUm9.js +1407 -0
- package/dist/index-DIvMCJQO.js +268 -0
- package/dist/index-vdsiw6gQ.js +777 -0
- package/dist/index.d.ts +9 -9
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +395 -825
- package/dist/minimal-prod.js +101 -155
- package/dist/minimal.js +104 -170
- package/dist/modifiers/background.d.ts +41 -11
- package/dist/modifiers/background.d.ts.map +1 -1
- package/dist/modifiers/base.d.ts +6 -33
- package/dist/modifiers/base.d.ts.map +1 -1
- package/dist/modifiers/base.js +487 -0
- package/dist/modifiers/builder.d.ts +103 -195
- package/dist/modifiers/builder.d.ts.map +1 -1
- package/dist/modifiers/builder.js +9 -0
- package/dist/modifiers/core.d.ts +9 -401
- package/dist/modifiers/core.d.ts.map +1 -1
- package/dist/modifiers/{utils.d.ts → factories.d.ts} +18 -5
- package/dist/modifiers/factories.d.ts.map +1 -0
- package/dist/modifiers/index.d.ts +8 -52
- package/dist/modifiers/index.d.ts.map +1 -1
- package/dist/modifiers/index.js +38 -0
- package/dist/modifiers/presets.d.ts +368 -0
- package/dist/modifiers/presets.d.ts.map +1 -0
- package/dist/modifiers/registry.js +10 -0
- package/dist/modifiers/types.d.ts +39 -211
- package/dist/modifiers/types.d.ts.map +1 -1
- package/dist/modifiers/types.js +4 -0
- package/dist/performance-optimizer-stub-CtfXUwl4.js +38 -0
- package/dist/plugins/index.d.ts +5 -6
- package/dist/plugins/index.d.ts.map +1 -1
- package/dist/plugins/index.js +147 -297
- package/dist/plugins/simplified-index.d.ts +5 -6
- package/dist/plugins/simplified-index.d.ts.map +1 -1
- package/dist/production-minimal-BY_gMc-l.js +2532 -0
- package/dist/reactive/index.js +96 -95
- package/dist/reactive/types.js +4 -0
- package/dist/runtime/dom-bridge.js +5 -5
- package/dist/runtime/element-override.d.ts.map +1 -1
- package/dist/runtime/index.d.ts +0 -7
- package/dist/runtime/index.d.ts.map +1 -1
- package/dist/runtime/renderer.d.ts.map +1 -1
- package/dist/runtime/renderer.js +7 -8
- package/dist/runtime/semantic-role-manager.d.ts.map +1 -1
- package/dist/runtime/types.js +1 -0
- package/dist/{scheduler-7SvC3a21.js → scheduler-BKeqwrYE.js} +130 -130
- package/dist/validation/build-time-stub.d.ts +33 -0
- package/dist/validation/build-time-stub.d.ts.map +1 -0
- package/dist/validation/debug-tools-stub.d.ts +67 -0
- package/dist/validation/debug-tools-stub.d.ts.map +1 -0
- package/dist/validation/index.d.ts +23 -78
- package/dist/validation/index.d.ts.map +1 -1
- package/dist/validation/index.js +609 -6470
- package/dist/validation/lifecycle-validation.d.ts.map +1 -1
- package/dist/validation/performance-optimizer-stub.d.ts +50 -0
- package/dist/validation/performance-optimizer-stub.d.ts.map +1 -0
- package/dist/validation/plugin-registration.d.ts +5 -1
- package/dist/validation/plugin-registration.d.ts.map +1 -1
- package/dist/validation/production-bypass-core.d.ts +69 -0
- package/dist/validation/production-bypass-core.d.ts.map +1 -0
- package/package.json +41 -5
- package/dist/ScrollView-h-6wYMAm.js +0 -515
- package/dist/Spacer-BbteDQ9I.js +0 -5337
- package/dist/binding-CmdpowkI.js +0 -2276
- package/dist/components/BasicInput.d.ts +0 -116
- package/dist/components/BasicInput.d.ts.map +0 -1
- package/dist/components/Button.d.ts +0 -252
- package/dist/components/Button.d.ts.map +0 -1
- package/dist/components/Divider.d.ts +0 -141
- package/dist/components/Divider.d.ts.map +0 -1
- package/dist/components/EnhancedLink.d.ts +0 -365
- package/dist/components/EnhancedLink.d.ts.map +0 -1
- package/dist/components/Form.d.ts +0 -141
- package/dist/components/Form.d.ts.map +0 -1
- package/dist/components/Grid.d.ts +0 -698
- package/dist/components/Grid.d.ts.map +0 -1
- package/dist/components/GridResponsive.d.ts +0 -214
- package/dist/components/GridResponsive.d.ts.map +0 -1
- package/dist/components/Image.d.ts +0 -162
- package/dist/components/Image.d.ts.map +0 -1
- package/dist/components/List.d.ts +0 -287
- package/dist/components/List.d.ts.map +0 -1
- package/dist/components/Menu.d.ts +0 -159
- package/dist/components/Menu.d.ts.map +0 -1
- package/dist/components/Picker.d.ts +0 -153
- package/dist/components/Picker.d.ts.map +0 -1
- package/dist/components/ScrollView.d.ts +0 -222
- package/dist/components/ScrollView.d.ts.map +0 -1
- package/dist/components/Section.d.ts +0 -153
- package/dist/components/Section.d.ts.map +0 -1
- package/dist/components/Show.d.ts +0 -64
- package/dist/components/Show.d.ts.map +0 -1
- package/dist/components/Spacer.d.ts +0 -35
- package/dist/components/Spacer.d.ts.map +0 -1
- package/dist/components/Text.d.ts +0 -242
- package/dist/components/Text.d.ts.map +0 -1
- package/dist/components/Toggle.d.ts +0 -207
- package/dist/components/Toggle.d.ts.map +0 -1
- package/dist/concatenated-component-DPcl2TEO.js +0 -6779
- package/dist/context--zQFIImS.js +0 -283
- package/dist/debug/index.d.ts +0 -61
- package/dist/debug/index.d.ts.map +0 -1
- package/dist/debug.js +0 -178
- package/dist/developer-experience/enhanced-errors.d.ts +0 -128
- package/dist/developer-experience/enhanced-errors.d.ts.map +0 -1
- package/dist/developer-experience/enhanced-types.d.ts +0 -281
- package/dist/developer-experience/enhanced-types.d.ts.map +0 -1
- package/dist/developer-experience/index.d.ts +0 -44
- package/dist/developer-experience/index.d.ts.map +0 -1
- package/dist/index-Nfi2SBQh.js +0 -3268
- package/dist/modifiers/attributes.d.ts +0 -203
- package/dist/modifiers/attributes.d.ts.map +0 -1
- package/dist/modifiers/backdrop.d.ts +0 -59
- package/dist/modifiers/backdrop.d.ts.map +0 -1
- package/dist/modifiers/border.d.ts +0 -217
- package/dist/modifiers/border.d.ts.map +0 -1
- package/dist/modifiers/effects.d.ts +0 -159
- package/dist/modifiers/effects.d.ts.map +0 -1
- package/dist/modifiers/elements.d.ts +0 -240
- package/dist/modifiers/elements.d.ts.map +0 -1
- package/dist/modifiers/filters.d.ts +0 -275
- package/dist/modifiers/filters.d.ts.map +0 -1
- package/dist/modifiers/flexbox.d.ts +0 -82
- package/dist/modifiers/flexbox.d.ts.map +0 -1
- package/dist/modifiers/font.d.ts +0 -71
- package/dist/modifiers/font.d.ts.map +0 -1
- package/dist/modifiers/grid.d.ts +0 -92
- package/dist/modifiers/grid.d.ts.map +0 -1
- package/dist/modifiers/margin.d.ts +0 -128
- package/dist/modifiers/margin.d.ts.map +0 -1
- package/dist/modifiers/padding.d.ts +0 -204
- package/dist/modifiers/padding.d.ts.map +0 -1
- package/dist/modifiers/responsive/advanced-utilities.d.ts +0 -118
- package/dist/modifiers/responsive/advanced-utilities.d.ts.map +0 -1
- package/dist/modifiers/responsive/breakpoints.d.ts +0 -81
- package/dist/modifiers/responsive/breakpoints.d.ts.map +0 -1
- package/dist/modifiers/responsive/css-generator.d.ts +0 -100
- package/dist/modifiers/responsive/css-generator.d.ts.map +0 -1
- package/dist/modifiers/responsive/dev-tools.d.ts +0 -107
- package/dist/modifiers/responsive/dev-tools.d.ts.map +0 -1
- package/dist/modifiers/responsive/index.d.ts +0 -29
- package/dist/modifiers/responsive/index.d.ts.map +0 -1
- package/dist/modifiers/responsive/layout-patterns.d.ts +0 -230
- package/dist/modifiers/responsive/layout-patterns.d.ts.map +0 -1
- package/dist/modifiers/responsive/performance.d.ts +0 -130
- package/dist/modifiers/responsive/performance.d.ts.map +0 -1
- package/dist/modifiers/responsive/responsive-builder.d.ts +0 -133
- package/dist/modifiers/responsive/responsive-builder.d.ts.map +0 -1
- package/dist/modifiers/responsive/responsive-modifier.d.ts +0 -123
- package/dist/modifiers/responsive/responsive-modifier.d.ts.map +0 -1
- package/dist/modifiers/responsive/types.d.ts +0 -183
- package/dist/modifiers/responsive/types.d.ts.map +0 -1
- package/dist/modifiers/responsive/utilities.d.ts +0 -149
- package/dist/modifiers/responsive/utilities.d.ts.map +0 -1
- package/dist/modifiers/scroll.d.ts +0 -143
- package/dist/modifiers/scroll.d.ts.map +0 -1
- package/dist/modifiers/shadows.d.ts +0 -114
- package/dist/modifiers/shadows.d.ts.map +0 -1
- package/dist/modifiers/size.d.ts +0 -113
- package/dist/modifiers/size.d.ts.map +0 -1
- package/dist/modifiers/text.d.ts +0 -147
- package/dist/modifiers/text.d.ts.map +0 -1
- package/dist/modifiers/transformations.d.ts +0 -329
- package/dist/modifiers/transformations.d.ts.map +0 -1
- package/dist/modifiers/transitions.d.ts +0 -98
- package/dist/modifiers/transitions.d.ts.map +0 -1
- package/dist/modifiers/typography.d.ts +0 -192
- package/dist/modifiers/typography.d.ts.map +0 -1
- package/dist/modifiers/utility.d.ts +0 -69
- package/dist/modifiers/utility.d.ts.map +0 -1
- package/dist/modifiers/utils.d.ts.map +0 -1
- package/dist/plugins/simplified-error-handler.d.ts +0 -83
- package/dist/plugins/simplified-error-handler.d.ts.map +0 -1
- package/dist/runtime/dev-tools.d.ts +0 -240
- package/dist/runtime/dev-tools.d.ts.map +0 -1
- package/dist/runtime/development-warnings.d.ts +0 -42
- package/dist/runtime/development-warnings.d.ts.map +0 -1
- package/dist/runtime/error-boundary.d.ts +0 -302
- package/dist/runtime/error-boundary.d.ts.map +0 -1
- package/dist/runtime/error-recovery.d.ts +0 -267
- package/dist/runtime/error-recovery.d.ts.map +0 -1
- package/dist/runtime/error-reporting.d.ts +0 -287
- package/dist/runtime/error-reporting.d.ts.map +0 -1
- package/dist/runtime/error-utils.d.ts +0 -204
- package/dist/runtime/error-utils.d.ts.map +0 -1
- package/dist/runtime/performance.d.ts +0 -217
- package/dist/runtime/performance.d.ts.map +0 -1
- package/dist/sui-compat.d.ts +0 -110
- package/dist/sui-compat.d.ts.map +0 -1
- package/dist/validation/advanced-debugging.d.ts +0 -319
- package/dist/validation/advanced-debugging.d.ts.map +0 -1
- package/dist/validation/build-time/detection.d.ts +0 -32
- package/dist/validation/build-time/detection.d.ts.map +0 -1
- package/dist/validation/build-time/index.d.ts +0 -84
- package/dist/validation/build-time/index.d.ts.map +0 -1
- package/dist/validation/build-time/plugins.d.ts +0 -75
- package/dist/validation/build-time/plugins.d.ts.map +0 -1
- package/dist/validation/build-time/rules.d.ts +0 -73
- package/dist/validation/build-time/rules.d.ts.map +0 -1
- package/dist/validation/build-time/transformer.d.ts +0 -23
- package/dist/validation/build-time/transformer.d.ts.map +0 -1
- package/dist/validation/build-time/types.d.ts +0 -212
- package/dist/validation/build-time/types.d.ts.map +0 -1
- package/dist/validation/comprehensive.d.ts +0 -160
- package/dist/validation/comprehensive.d.ts.map +0 -1
- package/dist/validation/debug-tools.d.ts +0 -251
- package/dist/validation/debug-tools.d.ts.map +0 -1
- package/dist/validation/developer-experience.d.ts +0 -243
- package/dist/validation/developer-experience.d.ts.map +0 -1
- package/dist/validation/documentation-integration.d.ts +0 -269
- package/dist/validation/documentation-integration.d.ts.map +0 -1
- package/dist/validation/enhanced-runtime.d.ts +0 -279
- package/dist/validation/enhanced-runtime.d.ts.map +0 -1
- package/dist/validation/error-reporting.d.ts +0 -186
- package/dist/validation/error-reporting.d.ts.map +0 -1
- package/dist/validation/ide-integration.d.ts +0 -328
- package/dist/validation/ide-integration.d.ts.map +0 -1
- package/dist/validation/performance-optimizer.d.ts +0 -218
- package/dist/validation/performance-optimizer.d.ts.map +0 -1
- package/dist/validation/production-bypass.d.ts +0 -175
- package/dist/validation/production-bypass.d.ts.map +0 -1
- package/dist/validation/simple.d.ts +0 -111
- package/dist/validation/simple.d.ts.map +0 -1
- package/dist/viewport/adapters/web-adapter.d.ts +0 -227
- package/dist/viewport/adapters/web-adapter.d.ts.map +0 -1
- package/dist/viewport/components.d.ts +0 -131
- package/dist/viewport/components.d.ts.map +0 -1
- package/dist/viewport/environment.d.ts +0 -75
- package/dist/viewport/environment.d.ts.map +0 -1
- package/dist/viewport/index.d.ts +0 -138
- package/dist/viewport/index.d.ts.map +0 -1
- package/dist/viewport/index.js +0 -2085
- package/dist/viewport/platform-detection.d.ts +0 -59
- package/dist/viewport/platform-detection.d.ts.map +0 -1
- package/dist/viewport/types.d.ts +0 -301
- package/dist/viewport/types.d.ts.map +0 -1
- package/dist/viewport/viewport-manager.d.ts +0 -118
- package/dist/viewport/viewport-manager.d.ts.map +0 -1
|
@@ -0,0 +1,368 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Pre-built SwiftUI-Style Modifiers
|
|
3
|
+
*
|
|
4
|
+
* Ready-to-use modifier implementations that mirror SwiftUI's modifier API.
|
|
5
|
+
* These provide the core building blocks for layout, appearance, interaction,
|
|
6
|
+
* animation, and lifecycle management.
|
|
7
|
+
*/
|
|
8
|
+
import type { Asset } from '../assets/Asset';
|
|
9
|
+
import type { Signal } from '../reactive/types';
|
|
10
|
+
import type { Dimension } from '../constants/layout';
|
|
11
|
+
import type { GradientDefinition } from '../gradients/types';
|
|
12
|
+
import type { AnimationModifierProps, AppearanceModifierProps, LayoutModifierProps, Modifier } from './types';
|
|
13
|
+
/**
|
|
14
|
+
* Layout Modifiers
|
|
15
|
+
*/
|
|
16
|
+
export declare const layoutModifiers: {
|
|
17
|
+
/**
|
|
18
|
+
* Set foreground (text) color
|
|
19
|
+
*/
|
|
20
|
+
foregroundColor(color: string | Signal<string> | any): Modifier;
|
|
21
|
+
/**
|
|
22
|
+
* Set frame dimensions with support for infinity
|
|
23
|
+
*/
|
|
24
|
+
frame(width?: Dimension, height?: Dimension, options?: Omit<LayoutModifierProps["frame"], "width" | "height">): Modifier;
|
|
25
|
+
/**
|
|
26
|
+
* Set padding on all sides
|
|
27
|
+
*/
|
|
28
|
+
padding(value: number): Modifier;
|
|
29
|
+
/**
|
|
30
|
+
* Set margin on all sides
|
|
31
|
+
*/
|
|
32
|
+
margin(value: number): Modifier;
|
|
33
|
+
/**
|
|
34
|
+
* Set content alignment
|
|
35
|
+
*/
|
|
36
|
+
alignment(value: LayoutModifierProps["alignment"]): Modifier;
|
|
37
|
+
/**
|
|
38
|
+
* Set layout priority for ZStack container sizing and flexible layout
|
|
39
|
+
* Higher priority views determine container size in ZStack
|
|
40
|
+
*/
|
|
41
|
+
layoutPriority(priority: number | Signal<number>): Modifier;
|
|
42
|
+
};
|
|
43
|
+
/**
|
|
44
|
+
* Appearance Modifiers
|
|
45
|
+
*/
|
|
46
|
+
export declare const appearanceModifiers: {
|
|
47
|
+
/**
|
|
48
|
+
* Set foreground (text) color
|
|
49
|
+
*/
|
|
50
|
+
foregroundColor(color: string | Asset | Signal<string>): Modifier;
|
|
51
|
+
/**
|
|
52
|
+
* Set background color
|
|
53
|
+
*/
|
|
54
|
+
backgroundColor(color: string | Asset | Signal<string>): Modifier;
|
|
55
|
+
/**
|
|
56
|
+
* Set background (supports gradients)
|
|
57
|
+
*/
|
|
58
|
+
background(value: string | GradientDefinition | Asset): Modifier;
|
|
59
|
+
/**
|
|
60
|
+
* Set font properties
|
|
61
|
+
*/
|
|
62
|
+
font(options: AppearanceModifierProps["font"]): Modifier;
|
|
63
|
+
/**
|
|
64
|
+
* Set font size
|
|
65
|
+
*/
|
|
66
|
+
fontSize(size: number | string): Modifier;
|
|
67
|
+
/**
|
|
68
|
+
* Set font weight
|
|
69
|
+
*/
|
|
70
|
+
fontWeight(weight: NonNullable<AppearanceModifierProps["font"]>["weight"]): Modifier;
|
|
71
|
+
/**
|
|
72
|
+
* Set font family
|
|
73
|
+
*/
|
|
74
|
+
fontFamily(family: string): Modifier;
|
|
75
|
+
/**
|
|
76
|
+
* Set opacity
|
|
77
|
+
*/
|
|
78
|
+
opacity(value: number | Signal<number>): Modifier;
|
|
79
|
+
/**
|
|
80
|
+
* Set corner radius (enhanced)
|
|
81
|
+
*/
|
|
82
|
+
cornerRadius(radius: number | Signal<number>): Modifier;
|
|
83
|
+
/**
|
|
84
|
+
* Set border
|
|
85
|
+
*/
|
|
86
|
+
border(width: number, color?: string | Asset, style?: "solid" | "dashed" | "dotted"): Modifier;
|
|
87
|
+
/**
|
|
88
|
+
* Set detailed border properties
|
|
89
|
+
*/
|
|
90
|
+
borderDetailed(options: AppearanceModifierProps["border"]): Modifier;
|
|
91
|
+
};
|
|
92
|
+
/**
|
|
93
|
+
* Interaction Modifiers
|
|
94
|
+
*/
|
|
95
|
+
export declare const interactionModifiers: {
|
|
96
|
+
/**
|
|
97
|
+
* Add tap handler
|
|
98
|
+
*/
|
|
99
|
+
onTap(handler: (event: MouseEvent) => void): Modifier;
|
|
100
|
+
/**
|
|
101
|
+
* Add hover handler
|
|
102
|
+
*/
|
|
103
|
+
onHover(handler: (isHovered: boolean) => void): Modifier;
|
|
104
|
+
/**
|
|
105
|
+
* Add focus handler
|
|
106
|
+
*/
|
|
107
|
+
onFocus(handler: (isFocused: boolean) => void): Modifier;
|
|
108
|
+
/**
|
|
109
|
+
* Set disabled state
|
|
110
|
+
*/
|
|
111
|
+
disabled(isDisabled?: boolean | Signal<boolean>): Modifier;
|
|
112
|
+
/**
|
|
113
|
+
* Set accessibility label
|
|
114
|
+
*/
|
|
115
|
+
accessibilityLabel(label: string): Modifier;
|
|
116
|
+
/**
|
|
117
|
+
* Set accessibility hint
|
|
118
|
+
*/
|
|
119
|
+
accessibilityHint(hint: string): Modifier;
|
|
120
|
+
};
|
|
121
|
+
/**
|
|
122
|
+
* Animation Modifiers
|
|
123
|
+
*/
|
|
124
|
+
export declare const animationModifiers: {
|
|
125
|
+
/**
|
|
126
|
+
* Add transition
|
|
127
|
+
*/
|
|
128
|
+
transition(property?: string, duration?: number, easing?: string, delay?: number): Modifier;
|
|
129
|
+
/**
|
|
130
|
+
* Add detailed transition
|
|
131
|
+
*/
|
|
132
|
+
transitionDetailed(options: AnimationModifierProps["transition"]): Modifier;
|
|
133
|
+
/**
|
|
134
|
+
* Add animation
|
|
135
|
+
*/
|
|
136
|
+
animation(options: AnimationModifierProps["animation"]): Modifier;
|
|
137
|
+
/**
|
|
138
|
+
* Add fade in animation
|
|
139
|
+
*/
|
|
140
|
+
fadeIn(duration?: number): Modifier;
|
|
141
|
+
/**
|
|
142
|
+
* Add fade out animation
|
|
143
|
+
*/
|
|
144
|
+
fadeOut(duration?: number): Modifier;
|
|
145
|
+
/**
|
|
146
|
+
* Add slide in animation
|
|
147
|
+
*/
|
|
148
|
+
slideIn(direction?: "up" | "down" | "left" | "right", duration?: number, distance?: number): Modifier;
|
|
149
|
+
/**
|
|
150
|
+
* Add scale animation
|
|
151
|
+
*/
|
|
152
|
+
scaleAnimation(from?: number, to?: number, duration?: number): Modifier;
|
|
153
|
+
};
|
|
154
|
+
/**
|
|
155
|
+
* Lifecycle Modifiers
|
|
156
|
+
*/
|
|
157
|
+
export declare const lifecycleModifiers: {
|
|
158
|
+
/**
|
|
159
|
+
* Execute handler when component appears in viewport
|
|
160
|
+
*/
|
|
161
|
+
onAppear(handler: () => void): Modifier;
|
|
162
|
+
/**
|
|
163
|
+
* Execute handler when component disappears from viewport
|
|
164
|
+
*/
|
|
165
|
+
onDisappear(handler: () => void): Modifier;
|
|
166
|
+
/**
|
|
167
|
+
* Execute async task with automatic cancellation on component unmount
|
|
168
|
+
*/
|
|
169
|
+
task(operation: () => Promise<void> | void, options?: {
|
|
170
|
+
id?: string;
|
|
171
|
+
priority?: "background" | "userInitiated" | "utility" | "default";
|
|
172
|
+
}): Modifier;
|
|
173
|
+
/**
|
|
174
|
+
* Add pull-to-refresh functionality
|
|
175
|
+
*/
|
|
176
|
+
refreshable(onRefresh: () => Promise<void>, isRefreshing?: boolean | Signal<boolean>): Modifier;
|
|
177
|
+
};
|
|
178
|
+
/**
|
|
179
|
+
* Preset Modifiers - Common combinations
|
|
180
|
+
*/
|
|
181
|
+
export declare const presetModifiers: {
|
|
182
|
+
/**
|
|
183
|
+
* Card-like appearance
|
|
184
|
+
*/
|
|
185
|
+
card(padding?: number): Modifier[];
|
|
186
|
+
/**
|
|
187
|
+
* Button-like appearance
|
|
188
|
+
*/
|
|
189
|
+
button(backgroundColor?: string | Asset, textColor?: string | Asset): Modifier[];
|
|
190
|
+
/**
|
|
191
|
+
* Input field appearance
|
|
192
|
+
*/
|
|
193
|
+
input(): Modifier[];
|
|
194
|
+
/**
|
|
195
|
+
* Typography presets
|
|
196
|
+
*/
|
|
197
|
+
typography: {
|
|
198
|
+
title: () => Modifier[];
|
|
199
|
+
heading: () => Modifier[];
|
|
200
|
+
body: () => Modifier[];
|
|
201
|
+
caption: () => Modifier[];
|
|
202
|
+
};
|
|
203
|
+
};
|
|
204
|
+
/**
|
|
205
|
+
* Export all preset modifiers
|
|
206
|
+
*/
|
|
207
|
+
export declare const coreModifiers: {
|
|
208
|
+
presets: {
|
|
209
|
+
/**
|
|
210
|
+
* Card-like appearance
|
|
211
|
+
*/
|
|
212
|
+
card(padding?: number): Modifier[];
|
|
213
|
+
/**
|
|
214
|
+
* Button-like appearance
|
|
215
|
+
*/
|
|
216
|
+
button(backgroundColor?: string | Asset, textColor?: string | Asset): Modifier[];
|
|
217
|
+
/**
|
|
218
|
+
* Input field appearance
|
|
219
|
+
*/
|
|
220
|
+
input(): Modifier[];
|
|
221
|
+
/**
|
|
222
|
+
* Typography presets
|
|
223
|
+
*/
|
|
224
|
+
typography: {
|
|
225
|
+
title: () => Modifier[];
|
|
226
|
+
heading: () => Modifier[];
|
|
227
|
+
body: () => Modifier[];
|
|
228
|
+
caption: () => Modifier[];
|
|
229
|
+
};
|
|
230
|
+
};
|
|
231
|
+
/**
|
|
232
|
+
* Execute handler when component appears in viewport
|
|
233
|
+
*/
|
|
234
|
+
onAppear(handler: () => void): Modifier;
|
|
235
|
+
/**
|
|
236
|
+
* Execute handler when component disappears from viewport
|
|
237
|
+
*/
|
|
238
|
+
onDisappear(handler: () => void): Modifier;
|
|
239
|
+
/**
|
|
240
|
+
* Execute async task with automatic cancellation on component unmount
|
|
241
|
+
*/
|
|
242
|
+
task(operation: () => Promise<void> | void, options?: {
|
|
243
|
+
id?: string;
|
|
244
|
+
priority?: "background" | "userInitiated" | "utility" | "default";
|
|
245
|
+
}): Modifier;
|
|
246
|
+
/**
|
|
247
|
+
* Add pull-to-refresh functionality
|
|
248
|
+
*/
|
|
249
|
+
refreshable(onRefresh: () => Promise<void>, isRefreshing?: boolean | Signal<boolean>): Modifier;
|
|
250
|
+
/**
|
|
251
|
+
* Add transition
|
|
252
|
+
*/
|
|
253
|
+
transition(property?: string, duration?: number, easing?: string, delay?: number): Modifier;
|
|
254
|
+
/**
|
|
255
|
+
* Add detailed transition
|
|
256
|
+
*/
|
|
257
|
+
transitionDetailed(options: AnimationModifierProps["transition"]): Modifier;
|
|
258
|
+
/**
|
|
259
|
+
* Add animation
|
|
260
|
+
*/
|
|
261
|
+
animation(options: AnimationModifierProps["animation"]): Modifier;
|
|
262
|
+
/**
|
|
263
|
+
* Add fade in animation
|
|
264
|
+
*/
|
|
265
|
+
fadeIn(duration?: number): Modifier;
|
|
266
|
+
/**
|
|
267
|
+
* Add fade out animation
|
|
268
|
+
*/
|
|
269
|
+
fadeOut(duration?: number): Modifier;
|
|
270
|
+
/**
|
|
271
|
+
* Add slide in animation
|
|
272
|
+
*/
|
|
273
|
+
slideIn(direction?: "up" | "down" | "left" | "right", duration?: number, distance?: number): Modifier;
|
|
274
|
+
/**
|
|
275
|
+
* Add scale animation
|
|
276
|
+
*/
|
|
277
|
+
scaleAnimation(from?: number, to?: number, duration?: number): Modifier;
|
|
278
|
+
/**
|
|
279
|
+
* Add tap handler
|
|
280
|
+
*/
|
|
281
|
+
onTap(handler: (event: MouseEvent) => void): Modifier;
|
|
282
|
+
/**
|
|
283
|
+
* Add hover handler
|
|
284
|
+
*/
|
|
285
|
+
onHover(handler: (isHovered: boolean) => void): Modifier;
|
|
286
|
+
/**
|
|
287
|
+
* Add focus handler
|
|
288
|
+
*/
|
|
289
|
+
onFocus(handler: (isFocused: boolean) => void): Modifier;
|
|
290
|
+
/**
|
|
291
|
+
* Set disabled state
|
|
292
|
+
*/
|
|
293
|
+
disabled(isDisabled?: boolean | Signal<boolean>): Modifier;
|
|
294
|
+
/**
|
|
295
|
+
* Set accessibility label
|
|
296
|
+
*/
|
|
297
|
+
accessibilityLabel(label: string): Modifier;
|
|
298
|
+
/**
|
|
299
|
+
* Set accessibility hint
|
|
300
|
+
*/
|
|
301
|
+
accessibilityHint(hint: string): Modifier;
|
|
302
|
+
/**
|
|
303
|
+
* Set foreground (text) color
|
|
304
|
+
*/
|
|
305
|
+
foregroundColor(color: string | Asset | Signal<string>): Modifier;
|
|
306
|
+
/**
|
|
307
|
+
* Set background color
|
|
308
|
+
*/
|
|
309
|
+
backgroundColor(color: string | Asset | Signal<string>): Modifier;
|
|
310
|
+
/**
|
|
311
|
+
* Set background (supports gradients)
|
|
312
|
+
*/
|
|
313
|
+
background(value: string | GradientDefinition | Asset): Modifier;
|
|
314
|
+
/**
|
|
315
|
+
* Set font properties
|
|
316
|
+
*/
|
|
317
|
+
font(options: AppearanceModifierProps["font"]): Modifier;
|
|
318
|
+
/**
|
|
319
|
+
* Set font size
|
|
320
|
+
*/
|
|
321
|
+
fontSize(size: number | string): Modifier;
|
|
322
|
+
/**
|
|
323
|
+
* Set font weight
|
|
324
|
+
*/
|
|
325
|
+
fontWeight(weight: NonNullable<AppearanceModifierProps["font"]>["weight"]): Modifier;
|
|
326
|
+
/**
|
|
327
|
+
* Set font family
|
|
328
|
+
*/
|
|
329
|
+
fontFamily(family: string): Modifier;
|
|
330
|
+
/**
|
|
331
|
+
* Set opacity
|
|
332
|
+
*/
|
|
333
|
+
opacity(value: number | Signal<number>): Modifier;
|
|
334
|
+
/**
|
|
335
|
+
* Set corner radius (enhanced)
|
|
336
|
+
*/
|
|
337
|
+
cornerRadius(radius: number | Signal<number>): Modifier;
|
|
338
|
+
/**
|
|
339
|
+
* Set border
|
|
340
|
+
*/
|
|
341
|
+
border(width: number, color?: string | Asset, style?: "solid" | "dashed" | "dotted"): Modifier;
|
|
342
|
+
/**
|
|
343
|
+
* Set detailed border properties
|
|
344
|
+
*/
|
|
345
|
+
borderDetailed(options: AppearanceModifierProps["border"]): Modifier;
|
|
346
|
+
/**
|
|
347
|
+
* Set frame dimensions with support for infinity
|
|
348
|
+
*/
|
|
349
|
+
frame(width?: Dimension, height?: Dimension, options?: Omit<LayoutModifierProps["frame"], "width" | "height">): Modifier;
|
|
350
|
+
/**
|
|
351
|
+
* Set padding on all sides
|
|
352
|
+
*/
|
|
353
|
+
padding(value: number): Modifier;
|
|
354
|
+
/**
|
|
355
|
+
* Set margin on all sides
|
|
356
|
+
*/
|
|
357
|
+
margin(value: number): Modifier;
|
|
358
|
+
/**
|
|
359
|
+
* Set content alignment
|
|
360
|
+
*/
|
|
361
|
+
alignment(value: LayoutModifierProps["alignment"]): Modifier;
|
|
362
|
+
/**
|
|
363
|
+
* Set layout priority for ZStack container sizing and flexible layout
|
|
364
|
+
* Higher priority views determine container size in ZStack
|
|
365
|
+
*/
|
|
366
|
+
layoutPriority(priority: number | Signal<number>): Modifier;
|
|
367
|
+
};
|
|
368
|
+
//# sourceMappingURL=presets.d.ts.map
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|
3
|
+
o as ModifierRegistryImpl,
|
|
4
|
+
a as applyModifiersToNode,
|
|
5
|
+
r as createModifiableComponent,
|
|
6
|
+
s as createModifierRegistry,
|
|
7
|
+
t as globalModifierRegistry,
|
|
8
|
+
d as modifierApplicationUtils,
|
|
9
|
+
p as updateComponentModifiers
|
|
10
|
+
};
|