@fewbox/den-web 0.2.0-preview.3 → 0.2.0-preview.30
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/engine.js +2 -0
- package/engine.js.map +1 -0
- package/{index-constants.d.ts → index-engine.d.ts} +15 -22
- package/index.css +1 -1
- package/index.js +1 -1
- package/index.js.map +1 -1
- package/package.json +6 -7
- package/scripts/generate-packages.js +5 -7
- package/server.js +71 -0
- package/src/components/Engine/Base/index.d.ts +3 -3
- package/src/components/Engine/index.d.ts +21 -14
- package/src/components/Layout/Dock/DockPopoverOverlay/index.d.ts +13 -0
- package/src/components/Layout/Dock/DockPortalOverlay/index.d.ts +11 -0
- package/src/components/Layout/Dock/index.d.ts +8 -26
- package/src/components/Layout/Dock/types.d.ts +39 -0
- package/src/components/View/VAside/index.d.ts +5 -0
- package/src/components/View/VErrorBoundary/index.d.ts +1 -1
- package/src/components/View/VForm/index.d.ts +1 -0
- package/src/components/View/VInput/VDropdown/index.d.ts +2 -0
- package/src/components/View/VInput/VFile/index.d.ts +2 -1
- package/src/components/View/VNav/index.d.ts +5 -0
- package/src/components/View/VTextArea/index.d.ts +1 -4
- package/src/components/View/VTooltip/index.d.ts +1 -4
- package/src/components/View/VTree/Block/index.d.ts +1 -1
- package/src/components/View/VTree/index.d.ts +2 -6
- package/src/components/View/VTree/types.d.ts +6 -0
- package/src/components/core.d.ts +3 -1
- package/templates/.claude/skills/fewbox-den/SKILL.md +52 -28
- package/templates/style/_core.scss +12 -0
- package/templates/style/_root-properties.scss +4 -1
- package/templates/style/_variables.scss +13 -1
- package/tsconfig.app.tsbuildinfo +1 -1
- package/constants.js +0 -2
- package/constants.js.map +0 -1
- package/src/components/View/VDynamic/index.d.ts +0 -7
- package/src/components/app.d.ts +0 -21
- package/src/fewbox/index.d.ts +0 -42
- package/src/language/index.d.ts +0 -13
- package/src/network/FormHeaders.d.ts +0 -4
- package/src/network/IGraphQL.d.ts +0 -6
- package/src/network/JsonHeaders.d.ts +0 -5
- package/src/network/Network.d.ts +0 -45
- package/src/network/NetworkObservableBase.d.ts +0 -14
- package/src/network/StreamObservableBase.d.ts +0 -11
- package/src/network/UploadHeaders.d.ts +0 -4
- package/src/network/WS.d.ts +0 -11
- package/src/network/ajax/default/Delete.d.ts +0 -5
- package/src/network/ajax/default/DeleteText.d.ts +0 -5
- package/src/network/ajax/default/Get.d.ts +0 -5
- package/src/network/ajax/default/GetLocal.d.ts +0 -5
- package/src/network/ajax/default/GetText.d.ts +0 -5
- package/src/network/ajax/default/NetworkObservableAjax.d.ts +0 -7
- package/src/network/ajax/default/Patch.d.ts +0 -5
- package/src/network/ajax/default/PatchText.d.ts +0 -5
- package/src/network/ajax/default/Post.d.ts +0 -5
- package/src/network/ajax/default/PostText.d.ts +0 -5
- package/src/network/ajax/default/Put.d.ts +0 -5
- package/src/network/ajax/default/PutText.d.ts +0 -5
- package/src/network/ajax/external/DeleteExternal.d.ts +0 -5
- package/src/network/ajax/external/DeleteTextExternal.d.ts +0 -5
- package/src/network/ajax/external/GetExternal.d.ts +0 -5
- package/src/network/ajax/external/GetTextExternal.d.ts +0 -5
- package/src/network/ajax/external/NetworkObservableAjaxExternal.d.ts +0 -8
- package/src/network/ajax/external/PatchExternal.d.ts +0 -5
- package/src/network/ajax/external/PatchTextExternal.d.ts +0 -5
- package/src/network/ajax/external/PostExternal.d.ts +0 -5
- package/src/network/ajax/external/PostTextExternal.d.ts +0 -5
- package/src/network/ajax/external/PutExternal.d.ts +0 -5
- package/src/network/ajax/external/PutTextExternal.d.ts +0 -5
- package/src/network/fetch/default/DeleteFetch.d.ts +0 -5
- package/src/network/fetch/default/GetFetch.d.ts +0 -5
- package/src/network/fetch/default/NetworkObservableFetch.d.ts +0 -7
- package/src/network/fetch/default/PatchFetch.d.ts +0 -5
- package/src/network/fetch/default/PostFetch.d.ts +0 -5
- package/src/network/fetch/default/PutFetch.d.ts +0 -5
- package/src/network/fetch/external/DeleteFetchExternal.d.ts +0 -5
- package/src/network/fetch/external/GetFetchExternal.d.ts +0 -5
- package/src/network/fetch/external/NetworkObservableFetchExternal.d.ts +0 -8
- package/src/network/fetch/external/PatchFetchExternal.d.ts +0 -5
- package/src/network/fetch/external/PostFetchExternal.d.ts +0 -5
- package/src/network/fetch/external/PutFetchExternal.d.ts +0 -5
- package/src/network/graphql/default/GQL.d.ts +0 -6
- package/src/network/graphql/default/GQLUpload.d.ts +0 -5
- package/src/network/graphql/default/NetworkObservableGQL.d.ts +0 -7
- package/src/network/graphql/external/GQLExternal.d.ts +0 -6
- package/src/network/graphql/external/GQLExternalUpload.d.ts +0 -6
- package/src/network/graphql/external/NetworkObservableGQLExternal.d.ts +0 -7
- package/src/network/index.d.ts +0 -50
- package/src/network/sse/default/GetSSE.d.ts +0 -5
- package/src/network/sse/default/PostSSE.d.ts +0 -5
- package/src/network/sse/default/StreamObservableSSE.d.ts +0 -5
- package/src/network/sse/external/GetSSEExternal.d.ts +0 -5
- package/src/network/sse/external/PostSSEExternal.d.ts +0 -5
- package/src/network/sse/external/StreamObservableSSEExternal.d.ts +0 -6
- package/src/network/util.d.ts +0 -5
|
@@ -25,7 +25,7 @@ Den.Components.ColorType // enums are also under Components
|
|
|
25
25
|
|
|
26
26
|
### Variant Exports
|
|
27
27
|
|
|
28
|
-
- **core** (`Den.Components`): Layout (X/Y/S/Flex/FlexItem/Position/PositionArea/Dock/BreakpointDisplay/Responsive), View (VBoundary, VLabel, VText, VForm, VActionForm, VInput/*, VSelect, VDropdown, VSwitch, VImage, VSvg, VBackground, VAnimation, VTooltip, VLoading, VErrorBoundary, VShape/*, VHyperlink, VMask, VFrame, VTheme, VHeader/VMain/VFooter, VHR, VSection, VZone, VAudio, VVideo, VShadow), Enums, Types, utilities
|
|
28
|
+
- **core** (`Den.Components`): Layout (X/Y/S/Flex/FlexItem/Position/PositionArea/Dock/BreakpointDisplay/Responsive), View (VBoundary, VLabel, VText, VForm, VActionForm, VInput/*, VSelect, VDropdown, VSwitch, VImage, VSvg, VBackground, VAnimation, VTooltip, VLoading, VErrorBoundary, VShape/*, VHyperlink, VMask, VFrame, VTheme, VHeader/VNav/VMain/VAside/VFooter, VHR, VSection, VZone, VAudio, VVideo, VShadow), Enums, Types, utilities
|
|
29
29
|
- **web** (`Den.Components`): core + Debug, VGoogleFont, VChromeExtensionValidator, GoogleGrant, GoogleSignin, FigmaSignin, WeComSignin, parseJWT
|
|
30
30
|
- **app** (`Den.Components`): web + VDynamic, VAvatar, VBlock, VCard, VCardMedia, VCardSocial, VCardWindow, VPhoto, VStack, VTree
|
|
31
31
|
- **app** also exports: `Den.FewBox`, `Den.Language`, `Den.Network`, `Den.Store`
|
|
@@ -41,35 +41,35 @@ All components extend `IBaseProps` (which extends `IViewProps`) providing these
|
|
|
41
41
|
|------|------|-------------|
|
|
42
42
|
| `className` | `string` | Additional CSS classes |
|
|
43
43
|
| `style` | `CSSProperties` | Inline styles |
|
|
44
|
-
| `fontSize` | `FontSizeType \|
|
|
44
|
+
| `fontSize` | `FontSizeType \| Property.FontSize` | Font size preset or custom CSS value |
|
|
45
45
|
| `isAutoSize` | `boolean` | Use auto-responsive font size variant |
|
|
46
46
|
| `fontWeight` | `FontWeightType` | Font weight (Thin through Black) |
|
|
47
|
-
| `frontColor` | `ColorType \|
|
|
48
|
-
| `backgroundColor` | `ColorType \|
|
|
49
|
-
| `borderColor` | `ColorType \|
|
|
47
|
+
| `frontColor` | `ColorType \| Property.Color` | Text/foreground color |
|
|
48
|
+
| `backgroundColor` | `ColorType \| Property.Color` | Background color |
|
|
49
|
+
| `borderColor` | `ColorType \| Property.Color` | Border color |
|
|
50
50
|
| `borderDirection` | `DirectionType` | Which sides get the border |
|
|
51
|
-
| `borderRadius` | `BorderRadiusType \|
|
|
52
|
-
| `borderStyle` | `BorderStyleType \|
|
|
53
|
-
| `borderWidth` | `BorderWidthType \|
|
|
54
|
-
| `padding` | `PaddingType \|
|
|
55
|
-
| `margin` | `MarginType \|
|
|
56
|
-
| `opacity` | `OpacityType` | Opacity preset |
|
|
57
|
-
| `display` | `DisplayType \|
|
|
58
|
-
| `visibility` | `VisibilityType \|
|
|
59
|
-
| `cursor` | `CursorType \|
|
|
60
|
-
| `overflow` | `OverflowType \|
|
|
61
|
-
| `overflowX` | `OverflowXType \|
|
|
62
|
-
| `overflowY` | `OverflowYType \|
|
|
63
|
-
| `width` | `
|
|
64
|
-
| `height` | `
|
|
65
|
-
| `minWidth` | `
|
|
66
|
-
| `minHeight` | `
|
|
67
|
-
| `maxWidth` | `
|
|
68
|
-
| `maxHeight` | `
|
|
69
|
-
| `zIndex` | `
|
|
70
|
-
| `fontFamily` | `
|
|
71
|
-
| `letterSpacing` | `
|
|
72
|
-
| `lineHeight` | `
|
|
51
|
+
| `borderRadius` | `BorderRadiusType \| Property.BorderRadius` | Border radius preset or custom |
|
|
52
|
+
| `borderStyle` | `BorderStyleType \| Property.BorderStyle` | Border style preset or custom |
|
|
53
|
+
| `borderWidth` | `BorderWidthType \| Property.BorderWidth` | Border width preset or custom |
|
|
54
|
+
| `padding` | `PaddingType \| Property.Padding` | CSS padding (preset or custom) |
|
|
55
|
+
| `margin` | `MarginType \| Property.Margin` | CSS margin (preset or custom) |
|
|
56
|
+
| `opacity` | `OpacityType \| Property.Opacity` | Opacity preset or custom CSS value |
|
|
57
|
+
| `display` | `DisplayType \| Property.Display` | CSS display preset or custom |
|
|
58
|
+
| `visibility` | `VisibilityType \| Property.Visibility` | CSS visibility preset or custom |
|
|
59
|
+
| `cursor` | `CursorType \| Property.Cursor` | CSS cursor preset or custom |
|
|
60
|
+
| `overflow` | `OverflowType \| Property.Overflow` | CSS overflow preset or custom |
|
|
61
|
+
| `overflowX` | `OverflowXType \| Property.OverflowX` | CSS overflow-x preset or custom |
|
|
62
|
+
| `overflowY` | `OverflowYType \| Property.OverflowY` | CSS overflow-y preset or custom |
|
|
63
|
+
| `width` | `Property.Width` | CSS width |
|
|
64
|
+
| `height` | `Property.Height` | CSS height |
|
|
65
|
+
| `minWidth` | `Property.Width` | CSS min-width |
|
|
66
|
+
| `minHeight` | `Property.Width` | CSS min-height |
|
|
67
|
+
| `maxWidth` | `Property.Width` | CSS max-width |
|
|
68
|
+
| `maxHeight` | `Property.Width` | CSS max-height |
|
|
69
|
+
| `zIndex` | `Property.ZIndex` | CSS z-index |
|
|
70
|
+
| `fontFamily` | `Property.FontFamily` | CSS font-family |
|
|
71
|
+
| `letterSpacing` | `LetterSpacingType \| Property.LetterSpacing` | Letter spacing preset or custom CSS value |
|
|
72
|
+
| `lineHeight` | `Property.LineHeight` | CSS line-height |
|
|
73
73
|
| `selfShrink` | `number` | flex-shrink for the component itself |
|
|
74
74
|
| `selfGrow` | `number` | flex-grow for the component itself |
|
|
75
75
|
| `selfBasis` | `string` | flex-basis for the component itself |
|
|
@@ -146,7 +146,7 @@ FontWeightType.Black // 900
|
|
|
146
146
|
|
|
147
147
|
### Preset Enums (class-based styling)
|
|
148
148
|
|
|
149
|
-
These enums generate CSS classes.
|
|
149
|
+
These enums generate CSS classes. All `Full*Type` props accept either a preset enum value (applied as className) or a custom CSS value from `csstype` `Property.*` (applied as inline style):
|
|
150
150
|
|
|
151
151
|
```tsx
|
|
152
152
|
// Border Radius
|
|
@@ -167,6 +167,9 @@ MarginType.Default | .Normal | .ExtraSmall | .Small | .Large | .ExtraLarge
|
|
|
167
167
|
// Gap (for layout components)
|
|
168
168
|
GapType.Default | .Normal | .ExtraSmall | .Small | .Large | .ExtraLarge
|
|
169
169
|
|
|
170
|
+
// Letter Spacing
|
|
171
|
+
LetterSpacingType.Default | .Normal | .ExtraSmall | .Small | .Large | .ExtraLarge
|
|
172
|
+
|
|
170
173
|
// Opacity
|
|
171
174
|
OpacityType._0 | ._10 | ._20 | ._25 | ._30 | ._40 | ._50 | ._60 | ._70 | ._75 | ._80 | ._90 | ._100
|
|
172
175
|
|
|
@@ -549,6 +552,18 @@ For inline text. Renders as `<span>` by default, configurable to any inline/head
|
|
|
549
552
|
// Available categories:
|
|
550
553
|
// LabelCategory.Div, Span, H1-H6, Abbr, Strong, Em, Code, Pre,
|
|
551
554
|
// Blockquote, Mark, Del, Ins, Small, Sub, Sup, etc.
|
|
555
|
+
|
|
556
|
+
// fontWeight/fontSize with heading categories (H1-H6):
|
|
557
|
+
// When fontWeight or fontSize is set, VLabel adds CSS classes
|
|
558
|
+
// (.v-label-inherit-font-weight / .v-label-inherit-font-size)
|
|
559
|
+
// that apply `inherit` to the inner heading element, overriding
|
|
560
|
+
// browser defaults. Without these props, headings keep their
|
|
561
|
+
// browser default styles (e.g., H1 is bold and 2em).
|
|
562
|
+
<Den.Components.VLabel
|
|
563
|
+
category={Den.Components.LabelCategory.H1}
|
|
564
|
+
fontWeight={Den.Components.FontWeightType.Thin}
|
|
565
|
+
caption="Thin H1"
|
|
566
|
+
/>
|
|
552
567
|
```
|
|
553
568
|
|
|
554
569
|
### VText (Block Text)
|
|
@@ -739,7 +754,14 @@ const [value, setValue] = useState('');
|
|
|
739
754
|
downIcon={<DownArrowIcon />} // required
|
|
740
755
|
upIcon={<UpArrowIcon />} // required
|
|
741
756
|
enableClear
|
|
757
|
+
readOnly // renders as VLabel (non-interactive)
|
|
758
|
+
isSelectOnly // prevents manual typing, only allows selection from items
|
|
759
|
+
menuGap="4px" // gap between dropdown menu and trigger
|
|
760
|
+
menuBackgroundColor={Den.Components.ColorType.White}
|
|
761
|
+
menuZIndex={9999}
|
|
742
762
|
handleChange={(value) => console.log(value)}
|
|
763
|
+
overWriteDropdownMenu={(items) => <CustomMenu items={items} />} // custom menu renderer
|
|
764
|
+
overWriteDropdownItem={(item) => <CustomItem item={item} />} // custom item renderer
|
|
743
765
|
/>
|
|
744
766
|
// IDropdownItemData: { caption: string; value: string; icon?: JSX.Element }
|
|
745
767
|
|
|
@@ -990,7 +1012,9 @@ Den.Components.parseJWT(token) // returns IUserProfile
|
|
|
990
1012
|
```tsx
|
|
991
1013
|
// Semantic HTML wrappers
|
|
992
1014
|
<Den.Components.VHeader>...</Den.Components.VHeader>
|
|
1015
|
+
<Den.Components.VNav>...</Den.Components.VNav>
|
|
993
1016
|
<Den.Components.VMain>...</Den.Components.VMain>
|
|
1017
|
+
<Den.Components.VAside>...</Den.Components.VAside>
|
|
994
1018
|
<Den.Components.VFooter>...</Den.Components.VFooter>
|
|
995
1019
|
<Den.Components.VSection>...</Den.Components.VSection>
|
|
996
1020
|
<Den.Components.VHR />
|
|
@@ -296,6 +296,18 @@ $border-positions: "all", "top", "right", "bottom", "left", "except-top", "excep
|
|
|
296
296
|
font-weight: var(#{v.$var-prefix}font-weight-#{$font-weight});
|
|
297
297
|
}
|
|
298
298
|
}
|
|
299
|
+
/* gap */
|
|
300
|
+
@each $gap, $value in v.$gaps {
|
|
301
|
+
.gap-#{$gap} {
|
|
302
|
+
gap: var(#{v.$var-prefix}gap-#{$gap});
|
|
303
|
+
}
|
|
304
|
+
}
|
|
305
|
+
/* letter-spacing */
|
|
306
|
+
@each $letter-spacing, $value in v.$letter-spacings {
|
|
307
|
+
.letter-spacing-#{$letter-spacing} {
|
|
308
|
+
letter-spacing: var(#{v.$var-prefix}letter-spacing-#{$letter-spacing});
|
|
309
|
+
}
|
|
310
|
+
}
|
|
299
311
|
/* padding */
|
|
300
312
|
@each $padding, $value in v.$paddings {
|
|
301
313
|
.padding-#{$padding} {
|
|
@@ -75,6 +75,9 @@
|
|
|
75
75
|
#{v.$var-prefix}font-size: #{v.$font-size};
|
|
76
76
|
#{v.$var-prefix}line-height: #{v.$line-height};
|
|
77
77
|
#{v.$var-prefix}letter-spacing: #{v.$letter-spacing};
|
|
78
|
+
@each $letter-spacing, $value in v.$letter-spacings {
|
|
79
|
+
#{v.$var-prefix}letter-spacing-#{$letter-spacing}: #{$value};
|
|
80
|
+
}
|
|
78
81
|
#{v.$var-prefix}padding: #{v.$padding};
|
|
79
82
|
#{v.$var-prefix}margin: #{v.$margin};
|
|
80
83
|
#{v.$var-prefix}box-sizing: #{v.$box-sizing};
|
|
@@ -93,7 +96,7 @@
|
|
|
93
96
|
#{v.$var-prefix}v-image-size: #{v.$v-image-size};
|
|
94
97
|
#{v.$var-prefix}v-svg-size: #{v.$v-svg-size};
|
|
95
98
|
#{v.$var-prefix}v-window--size: #{v.$v-window-size};
|
|
96
|
-
|
|
99
|
+
#{v.$var-prefix}position-offset: #{v.$position-offset};
|
|
97
100
|
|
|
98
101
|
*,
|
|
99
102
|
::before,
|
|
@@ -129,7 +129,7 @@ $margins: (
|
|
|
129
129
|
"extra-large": $margin-extra-large,
|
|
130
130
|
);
|
|
131
131
|
//left right top bottom offset
|
|
132
|
-
$
|
|
132
|
+
$position-offset: 1em;
|
|
133
133
|
//border
|
|
134
134
|
$border-radius-normal: 0.4rem;
|
|
135
135
|
$border-radius-extra-small: $border-radius-normal * 0.25;
|
|
@@ -252,6 +252,18 @@ $scrollbar-radius: 8px;
|
|
|
252
252
|
/*------------------*/
|
|
253
253
|
$line-height: 1.4;
|
|
254
254
|
$letter-spacing: 0.01em;
|
|
255
|
+
$letter-spacing-normal: 0.05em;
|
|
256
|
+
$letter-spacing-extra-small: $letter-spacing-normal * 0.5;
|
|
257
|
+
$letter-spacing-small: $letter-spacing-normal * 0.8;
|
|
258
|
+
$letter-spacing-large: $letter-spacing-normal * 1.4;
|
|
259
|
+
$letter-spacing-extra-large: $letter-spacing-normal * 2.4;
|
|
260
|
+
$letter-spacings: (
|
|
261
|
+
"normal": $letter-spacing-normal,
|
|
262
|
+
"extra-small": $letter-spacing-extra-small,
|
|
263
|
+
"small": $letter-spacing-small,
|
|
264
|
+
"large": $letter-spacing-large,
|
|
265
|
+
"extra-large": $letter-spacing-extra-large,
|
|
266
|
+
);
|
|
255
267
|
$font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji",
|
|
256
268
|
"Segoe UI Emoji", "Segoe UI Symbol";
|
|
257
269
|
$font-size: 1em; // 16px * 0.875 = 14px;
|