jfs-components 0.1.48 → 0.1.50
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/CHANGELOG.md +8 -1
- package/lib/commonjs/components/CardCTA/CardCTA.js +7 -4
- package/lib/commonjs/components/CardFeedback/CardFeedback.js +1 -1
- package/lib/commonjs/components/CategoryCard/CategoryCard.js +4 -4
- package/lib/commonjs/components/Checkbox/Checkbox.js +4 -6
- package/lib/commonjs/components/CircularProgressBarDoted/CircularProgressBarDoted.js +12 -9
- package/lib/commonjs/components/DonutChartSummary/DonutChartSummary.js +7 -2
- package/lib/commonjs/components/ProductMerchandisingCard/ProductMerchandisingCard.js +3 -1
- package/lib/commonjs/components/ProductOverview/ProductOverview.js +2 -2
- package/lib/commonjs/components/Radio/Radio.js +5 -3
- package/lib/commonjs/components/SavingsGoalSummary/SavingsGoalSummary.js +2 -2
- package/lib/commonjs/components/Section/Section.js +3 -1
- package/lib/commonjs/components/SegmentedControl/SegmentedControl.js +1 -1
- package/lib/commonjs/components/SegmentedTrack/SegmentedTrack.js +1 -1
- package/lib/commonjs/components/Slider/Slider.js +3 -2
- package/lib/commonjs/components/StatusHero/StatusHero.js +1 -1
- package/lib/commonjs/components/Tooltip/Tooltip.js +4 -2
- package/lib/commonjs/design-tokens/Coin Variables-variables-full.json +1 -1
- package/lib/commonjs/design-tokens/figma-modes.generated.js +38 -34
- package/lib/commonjs/icons/registry.js +1 -1
- package/lib/module/components/CardCTA/CardCTA.js +7 -4
- package/lib/module/components/CardFeedback/CardFeedback.js +1 -1
- package/lib/module/components/CategoryCard/CategoryCard.js +4 -4
- package/lib/module/components/Checkbox/Checkbox.js +4 -6
- package/lib/module/components/CircularProgressBarDoted/CircularProgressBarDoted.js +12 -9
- package/lib/module/components/DonutChartSummary/DonutChartSummary.js +7 -2
- package/lib/module/components/ProductMerchandisingCard/ProductMerchandisingCard.js +3 -1
- package/lib/module/components/ProductOverview/ProductOverview.js +2 -2
- package/lib/module/components/Radio/Radio.js +5 -3
- package/lib/module/components/SavingsGoalSummary/SavingsGoalSummary.js +2 -2
- package/lib/module/components/Section/Section.js +3 -1
- package/lib/module/components/SegmentedControl/SegmentedControl.js +1 -1
- package/lib/module/components/SegmentedTrack/SegmentedTrack.js +1 -1
- package/lib/module/components/Slider/Slider.js +3 -2
- package/lib/module/components/StatusHero/StatusHero.js +1 -1
- package/lib/module/components/Tooltip/Tooltip.js +4 -2
- package/lib/module/design-tokens/Coin Variables-variables-full.json +1 -1
- package/lib/module/design-tokens/figma-modes.generated.js +38 -34
- package/lib/module/icons/registry.js +1 -1
- package/lib/typescript/src/components/Section/Section.d.ts +2 -1
- package/lib/typescript/src/design-tokens/figma-modes.generated.d.ts +6 -2
- package/lib/typescript/src/icons/registry.d.ts +1 -1
- package/package.json +1 -1
- package/src/components/CardCTA/CardCTA.tsx +7 -4
- package/src/components/CardFeedback/CardFeedback.tsx +1 -1
- package/src/components/CategoryCard/CategoryCard.tsx +4 -4
- package/src/components/Checkbox/Checkbox.tsx +4 -6
- package/src/components/CircularProgressBarDoted/CircularProgressBarDoted.tsx +12 -9
- package/src/components/DonutChartSummary/DonutChartSummary.tsx +6 -6
- package/src/components/ProductMerchandisingCard/ProductMerchandisingCard.tsx +3 -1
- package/src/components/ProductOverview/ProductOverview.tsx +2 -2
- package/src/components/Radio/Radio.tsx +8 -3
- package/src/components/SavingsGoalSummary/SavingsGoalSummary.tsx +3 -3
- package/src/components/Section/Section.tsx +121 -156
- package/src/components/SegmentedControl/SegmentedControl.tsx +1 -1
- package/src/components/SegmentedTrack/SegmentedTrack.tsx +1 -2
- package/src/components/Slider/Slider.tsx +3 -2
- package/src/components/StatusHero/StatusHero.tsx +1 -1
- package/src/components/Tooltip/Tooltip.tsx +4 -2
- package/src/design-tokens/Coin Variables-variables-full.json +1 -1
- package/src/design-tokens/figma-modes.generated.ts +38 -34
- package/src/icons/registry.ts +1 -1
- package/D2C.md +0 -113
|
@@ -26,6 +26,7 @@ export const FIGMA_MODES = {
|
|
|
26
26
|
"AccordionGroup / Output": ["Default"],
|
|
27
27
|
"AccountCard / Output": ["Default"],
|
|
28
28
|
"Action": ["True", "False"],
|
|
29
|
+
"Action Footer Radius": ["False", "True"],
|
|
29
30
|
"ActionFooter / Output": ["Default"],
|
|
30
31
|
"ActionNumpad / Output": ["Default"],
|
|
31
32
|
"ActionTile / Output": ["Default"],
|
|
@@ -59,11 +60,13 @@ export const FIGMA_MODES = {
|
|
|
59
60
|
"Button / Output": ["Default"],
|
|
60
61
|
"Button / Size": ["M", "S", "XS"],
|
|
61
62
|
"Button / State": ["Idle", "Hover", "Pressed", "Disabled"],
|
|
63
|
+
"Button Glass State": ["Idle", "Hover", "Pressed", "Disabled"],
|
|
64
|
+
"Button type": ["default", "glass"],
|
|
62
65
|
"ButtonGroup / Output": ["Default"],
|
|
63
66
|
"Calendar Glyph / Output": ["Default"],
|
|
64
67
|
"Calendar Glyph State": ["Idle", "notSaved", "saved"],
|
|
65
68
|
"Card / Output": ["Default"],
|
|
66
|
-
"Card
|
|
69
|
+
"Card Container": ["Default", "Plain"],
|
|
67
70
|
"Card Feedback / Output": ["Default"],
|
|
68
71
|
"Card Tab / output": ["Default"],
|
|
69
72
|
"Card Tab State": ["Default", "Active"],
|
|
@@ -107,7 +110,7 @@ export const FIGMA_MODES = {
|
|
|
107
110
|
"Context2": ["Default", "AppBar"],
|
|
108
111
|
"Context3": ["Default", "Transaction Bubble", "Balance & Cards", "Amount Input"],
|
|
109
112
|
"Context4": ["Default", "Chip", "Button", "Badge", "Badge/glass"],
|
|
110
|
-
"context5": ["Default", "Fullscreen Modal"],
|
|
113
|
+
"context5": ["Default", "Fullscreen Modal", "Mode 1"],
|
|
111
114
|
"context7": ["Default", "Card", "Page Hero"],
|
|
112
115
|
"Contrast Context": ["on dark", "on light"],
|
|
113
116
|
"Control Toggle ": ["Default"],
|
|
@@ -248,6 +251,7 @@ export const FIGMA_MODES = {
|
|
|
248
251
|
"Slot gap": ["S", "M", "L", "XL", "XS"],
|
|
249
252
|
"special button": ["Default"],
|
|
250
253
|
"Spinner / Output": ["Default"],
|
|
254
|
+
"Stack Context": ["Root", "Nested"],
|
|
251
255
|
"statGroup / Output": ["Default"],
|
|
252
256
|
"StatItem / Output": ["Default"],
|
|
253
257
|
"StatItem Label Position ": ["Top", "Bottom"],
|
|
@@ -304,7 +308,7 @@ export const FIGMA_COMPONENT_MODES: Record<string, readonly string[]> = {
|
|
|
304
308
|
"Accordion": ["Accordion States"],
|
|
305
309
|
"AccordionCheckbox": ["Color Mode", "context 10", "Profile Card Appearance"],
|
|
306
310
|
"AccountCard": ["AppearanceBrand", "Button / Size", "Button / State", "Color Mode", "Emphasis", "Page type"],
|
|
307
|
-
"ActionFooter": ["Color Mode", "context5"],
|
|
311
|
+
"ActionFooter": ["Color Mode", "Context", "context5", "Slot gap"],
|
|
308
312
|
"ActionTile": ["AppearanceBrand", "AppearanceSystem", "Color Mode", "Context", "Emphasis", "Icon Capsule Size", "Page type", "Semantic Intent"],
|
|
309
313
|
"Additem": ["AppearanceBrand", "AppearanceSystem", "Color Mode", "Context", "Emphasis", "Icon Capsule Size", "Page type", "Semantic Intent"],
|
|
310
314
|
"AllocationComparisonChart": ["Appearance / DataViz", "Color Mode", "Emphasis / DataViz"],
|
|
@@ -316,36 +320,36 @@ export const FIGMA_COMPONENT_MODES: Record<string, readonly string[]> = {
|
|
|
316
320
|
"AvatarGroup": ["Avatar Size", "Badge Size", "Context4"],
|
|
317
321
|
"Badge": ["AppearanceBrand", "AppearanceSystem", "Badge Size", "Color Mode", "Emphasis", "Semantic Intent"],
|
|
318
322
|
"Balance": ["Color Mode", "Context3"],
|
|
319
|
-
"BenefitCard": ["AppearanceBrand", "AppearanceSystem", "Avatar Size", "Badge Size", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "Context4", "Emphasis", "Nudge padding", "Page type", "Profile Card Appearance", "Semantic Intent", "Slot gap", "Text Appearance", "Text Sizes", "Weight"],
|
|
323
|
+
"BenefitCard": ["AppearanceBrand", "AppearanceSystem", "Avatar Size", "Badge Size", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "Context4", "Emphasis", "Nudge padding", "Page type", "Profile Card Appearance", "Semantic Intent", "Slot gap", "Text Appearance", "Text Sizes", "Weight"],
|
|
320
324
|
"BottomNav": ["Color Mode"],
|
|
321
325
|
"BottomNavItem": ["BottomNavItem / State", "Color Mode"],
|
|
322
326
|
"BrandChip": ["Avatar Size", "Badge Size", "Color Mode", "context 10", "Context4", "Profile Card Appearance"],
|
|
323
327
|
"BubbleChart": ["Appearance / DataViz", "Color Mode", "Context", "context 10", "Emphasis / DataViz", "Profile Card Appearance", "Text Appearance"],
|
|
324
|
-
"Button": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "Emphasis", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
325
|
-
"Card": ["AppearanceBrand", "AppearanceSystem", "
|
|
326
|
-
"CardAdvisory": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "circularProgressBar Size", "Color Mode", "Context", "context 10", "Emphasis", "Nudge padding", "Page type", "Profile Card Appearance", "Semantic Intent", "Slot gap"],
|
|
327
|
-
"CardBankAccount": ["AppearanceBrand", "AppearanceSystem", "Avatar Size", "Badge Size", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "Context4", "context5", "Emphasis", "List Item Style", "Page type", "Profile Card Appearance", "Semantic Intent", "Text Appearance", "Text Sizes", "Weight"],
|
|
328
|
-
"CardCTA": ["AppearanceBrand", "AppearanceSystem", "Avatar Size", "Badge Size", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "context 8", "Context4", "Emphasis", "Icon Capsule Size", "MediaBlock", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
328
|
+
"Button": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "Emphasis", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
329
|
+
"Card": ["AppearanceBrand", "AppearanceSystem", "Card Container", "Color Mode", "context 8", "Gap", "Page type", "Semantic Intent"],
|
|
330
|
+
"CardAdvisory": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "circularProgressBar Size", "Color Mode", "Context", "context 10", "Emphasis", "Nudge padding", "Page type", "Profile Card Appearance", "Semantic Intent", "Slot gap"],
|
|
331
|
+
"CardBankAccount": ["AppearanceBrand", "AppearanceSystem", "Avatar Size", "Badge Size", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "Context4", "context5", "Emphasis", "List Item Style", "Page type", "Profile Card Appearance", "Semantic Intent", "Text Appearance", "Text Sizes", "Weight"],
|
|
332
|
+
"CardCTA": ["AppearanceBrand", "AppearanceSystem", "Avatar Size", "Badge Size", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "context 8", "Context4", "Emphasis", "Icon Capsule Size", "MediaBlock", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
329
333
|
"CardFeedback": ["AppearanceBrand", "AppearanceSystem", "Color Mode"],
|
|
330
|
-
"CardFinancialCondition": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "circularProgressBar Size", "Color Mode", "Context", "context 10", "Emphasis", "Nudge padding", "Page type", "Profile Card Appearance", "Semantic Intent", "Slot gap"],
|
|
331
|
-
"CardInsight": ["Appearance / DataViz", "AppearanceBrand", "AppearanceSystem", "Badge Size", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "context 8", "Emphasis", "Emphasis / DataViz", "LinearProgress Size", "Nudge padding", "Page type", "Profile Card Appearance", "Semantic Intent", "Slot gap"],
|
|
334
|
+
"CardFinancialCondition": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "circularProgressBar Size", "Color Mode", "Context", "context 10", "Emphasis", "Nudge padding", "Page type", "Profile Card Appearance", "Semantic Intent", "Slot gap"],
|
|
335
|
+
"CardInsight": ["Appearance / DataViz", "AppearanceBrand", "AppearanceSystem", "Badge Size", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "context 8", "Emphasis", "Emphasis / DataViz", "LinearProgress Size", "Nudge padding", "Page type", "Profile Card Appearance", "Semantic Intent", "Slot gap"],
|
|
332
336
|
"CardProviderInfo": ["AppearanceBrand", "Avatar Size", "Badge Size", "Color Mode", "context 10", "Context4", "Profile Card Appearance"],
|
|
333
337
|
"Carousel": ["peekOffset"],
|
|
334
338
|
"CarouselCardAccounts": ["peekOffset"],
|
|
335
339
|
"CategoryCard": ["AppearanceBrand", "AppearanceSystem", "Badge Size", "Card Tab State", "Color Mode", "Emphasis", "Radius", "Semantic Intent"],
|
|
336
|
-
"CcCard": ["AppearanceBrand", "AppearanceSystem", "Avatar Size", "Badge Size", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "context 8", "Context2", "Context4", "context5", "context7", "Emphasis", "List Item Style", "ListItem State", "NavArrow Direction", "Page type", "Profile Card Appearance", "Radius", "Selectable", "Semantic Intent", "Text Appearance", "Text Sizes", "Weight"],
|
|
340
|
+
"CcCard": ["AppearanceBrand", "AppearanceSystem", "Avatar Size", "Badge Size", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "context 8", "Context2", "Context4", "context5", "context7", "Emphasis", "List Item Style", "ListItem State", "NavArrow Direction", "Page type", "Profile Card Appearance", "Radius", "Selectable", "Semantic Intent", "Text Appearance", "Text Sizes", "Weight"],
|
|
337
341
|
"Checkbox": ["Color Mode"],
|
|
338
342
|
"CheckboxGroup": ["Color Mode"],
|
|
339
343
|
"CheckboxItem": ["Color Mode"],
|
|
340
344
|
"ChipSelect": ["ChipSelect State", "Color Mode"],
|
|
341
345
|
"CircularProgressBar": ["AppearanceBrand", "AppearanceSystem", "circularProgressBar Size", "Color Mode", "Emphasis", "Semantic Intent"],
|
|
342
|
-
"CircularRating": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "Emphasis", "Nudge padding", "Page type", "Profile Card Appearance", "Semantic Intent", "Slot gap"],
|
|
346
|
+
"CircularRating": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "Emphasis", "Nudge padding", "Page type", "Profile Card Appearance", "Semantic Intent", "Slot gap"],
|
|
343
347
|
"ClusterBubble": ["Appearance / DataViz", "Color Mode", "Context", "context 10", "Emphasis / DataViz", "Profile Card Appearance", "Text Appearance"],
|
|
344
|
-
"CompareTable": ["Accordion States", "AppearanceBrand", "Button / Size", "Button / State", "Color Mode", "Emphasis", "Page type", "Radius"
|
|
345
|
-
"ComparisonBar": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "Emphasis", "Icon Capsule Size", "Page type", "Profile Card Appearance", "Radius", "Semantic Intent"],
|
|
348
|
+
"CompareTable": ["Accordion States", "AppearanceBrand", "Button / Size", "Button / State", "Color Mode", "Emphasis", "Page type", "Radius"],
|
|
349
|
+
"ComparisonBar": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "Emphasis", "Icon Capsule Size", "Page type", "Profile Card Appearance", "Radius", "Semantic Intent"],
|
|
346
350
|
"ContentSheet": ["Color Mode", "Page type"],
|
|
347
351
|
"CoverageBarComparison": ["Appearance / DataViz", "Color Mode", "Emphasis / DataViz"],
|
|
348
|
-
"CoverageRing": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "circularProgressBar Size", "Color Mode", "Context", "context 10", "Emphasis", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
352
|
+
"CoverageRing": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "circularProgressBar Size", "Color Mode", "Context", "context 10", "Emphasis", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
349
353
|
"DebitCard": ["DebitCard brand"],
|
|
350
354
|
"Disclaimer": ["Color Mode", "context5"],
|
|
351
355
|
"Divider": ["Color Mode", "context 10", "Profile Card Appearance"],
|
|
@@ -354,20 +358,20 @@ export const FIGMA_COMPONENT_MODES: Record<string, readonly string[]> = {
|
|
|
354
358
|
"Drawer": ["Color Mode", "Page type"],
|
|
355
359
|
"Dropdown": ["Dropdown Item State"],
|
|
356
360
|
"DropdownInput": ["AppearanceBrand", "Button / State", "Color Mode", "Dropdown Item State", "Emphasis", "FormField States", "Page type", "Status"],
|
|
357
|
-
"EmptyState": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "Emphasis", "Icon Capsule Size", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
358
|
-
"ExpandableCheckbox": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "Emphasis", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
361
|
+
"EmptyState": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "Emphasis", "Icon Capsule Size", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
362
|
+
"ExpandableCheckbox": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "Emphasis", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
359
363
|
"FavoriteToggle": ["Color Mode", "Favorite Toggle Color", "Favorite Toggle Size"],
|
|
360
364
|
"FilterBar": ["Color Mode", "InputState"],
|
|
361
365
|
"FormField": ["Color Mode", "FormField States", "Status"],
|
|
362
366
|
"FormUpload": ["AppearanceBrand", "AppearanceSystem", "Color Mode", "Context", "Emphasis", "FormField States", "Icon Capsule Size", "Page type", "Semantic Intent", "Status"],
|
|
363
|
-
"FullscreenModal": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "context5", "Emphasis", "Page type", "PageHero Size", "Profile Card Appearance", "Semantic Intent", "Slot gap"],
|
|
367
|
+
"FullscreenModal": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "context5", "Emphasis", "Page type", "PageHero Size", "Profile Card Appearance", "Semantic Intent", "Slot gap"],
|
|
364
368
|
"Gauge": ["AppearanceBrand", "AppearanceSystem", "Color Mode", "FormField States", "Semantic Intent", "Status"],
|
|
365
369
|
"Grid": ["Background", "Color Mode", "Context", "Grid Gap", "Padding", "Page type", "Slot gap"],
|
|
366
|
-
"HelloJioInput": ["AppearanceBrand", "Button / Size", "Button / State", "Color Mode", "Emphasis", "Hello Jio Input Size", "Hello Jio Input State", "Page type"],
|
|
370
|
+
"HelloJioInput": ["AppearanceBrand", "Button / Size", "Button / State", "Color Mode", "Context2", "Emphasis", "Hello Jio Input Size", "Hello Jio Input State", "Page type"],
|
|
367
371
|
"HeroSection": ["AppearanceBrand", "Button / Size", "Button / State", "Color Mode", "context 9", "context7", "Emphasis", "FormField States", "InputState", "Page type", "Status"],
|
|
368
372
|
"HoldingsCard": ["AppearanceBrand", "Color Mode"],
|
|
369
|
-
"HStack": ["Context", "Padding", "Page type", "Slot gap"],
|
|
370
|
-
"Icon": ["AppearanceBrand", "
|
|
373
|
+
"HStack": ["Context", "Padding", "Page type", "Slot gap", "Stack Context"],
|
|
374
|
+
"Icon": ["AppearanceBrand", "Badge Size", "Color Mode", "context 10", "Context4", "Emphasis", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
371
375
|
"IconButton": ["AppearanceBrand", "Button / Size", "Button / State", "Color Mode", "Emphasis", "Page type"],
|
|
372
376
|
"IconCapsule": ["AppearanceBrand", "AppearanceSystem", "Color Mode", "Context", "Emphasis", "Icon Capsule Size", "Page type", "Semantic Intent"],
|
|
373
377
|
"InputSearch": ["Color Mode", "FormField States", "InputState", "Status"],
|
|
@@ -377,26 +381,26 @@ export const FIGMA_COMPONENT_MODES: Record<string, readonly string[]> = {
|
|
|
377
381
|
"Link": ["Color Mode", "Context", "context 10", "Profile Card Appearance", "Text Appearance", "Text Sizes", "Weight"],
|
|
378
382
|
"ListGroup": ["Color Mode", "List Item Style", "Title Level"],
|
|
379
383
|
"ListItem": ["AppearanceBrand", "Color Mode", "context 10", "Context2", "context5", "List Item Style", "ListItem State", "NavArrow Direction", "Page type", "Profile Card Appearance", "Selectable"],
|
|
380
|
-
"LottieIntroBlock": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "Emphasis", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
384
|
+
"LottieIntroBlock": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "Emphasis", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
381
385
|
"LottiePlayer": ["Video / Output"],
|
|
382
386
|
"MediaCard": ["Contrast Context"],
|
|
383
387
|
"MerchantProfile": ["Avatar Size", "Badge Size", "Color Mode", "context 10", "Context4", "Profile Card Appearance"],
|
|
384
388
|
"MessageField": ["Color Mode", "FormField States"],
|
|
385
|
-
"MetricData": ["AppearanceBrand", "
|
|
389
|
+
"MetricData": ["AppearanceBrand", "Badge Size", "Color Mode", "context 10", "Context4", "Emphasis", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
386
390
|
"MetricLegendItem": ["Appearance / DataViz", "Color Mode", "Emphasis / DataViz"],
|
|
387
391
|
"MoneyValue": ["Color Mode", "Context3"],
|
|
388
392
|
"MonthlyStatusGrid": ["Appearance / DataViz", "Calendar Glyph State", "Color Mode", "Emphasis / DataViz"],
|
|
389
393
|
"NavArrow": ["Color Mode", "context 10", "Context2", "context5", "List Item Style", "NavArrow Direction", "Page type", "Profile Card Appearance"],
|
|
390
|
-
"Nudge": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "Emphasis", "Nudge padding", "Page type", "Profile Card Appearance", "Semantic Intent", "Slot gap"],
|
|
391
|
-
"OTP": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "Emphasis", "FormField States", "Input/PINSlot States", "Page type", "Profile Card Appearance", "Semantic Intent", "Status"],
|
|
392
|
-
"PageHero": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "Emphasis", "Page type", "PageHero Size", "Profile Card Appearance", "Semantic Intent", "Video / Output"],
|
|
394
|
+
"Nudge": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "Emphasis", "Nudge padding", "Page type", "Profile Card Appearance", "Semantic Intent", "Slot gap"],
|
|
395
|
+
"OTP": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "Emphasis", "FormField States", "Input/PINSlot States", "Page type", "Profile Card Appearance", "Semantic Intent", "Status"],
|
|
396
|
+
"PageHero": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "Emphasis", "Page type", "PageHero Size", "Profile Card Appearance", "Semantic Intent", "Video / Output"],
|
|
393
397
|
"PaymentFeedback": ["AppearanceBrand", "AppearanceSystem", "Color Mode", "Context", "Emphasis", "Icon Capsule Size", "Page type", "Semantic Intent"],
|
|
394
|
-
"PdpCcCard": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "context7", "Emphasis", "Page type", "Profile Card Appearance", "Radius", "Semantic Intent"],
|
|
398
|
+
"PdpCcCard": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "context7", "Emphasis", "Page type", "Profile Card Appearance", "Radius", "Semantic Intent"],
|
|
395
399
|
"PlanComparisonCard": ["Color Mode"],
|
|
396
|
-
"Popup": ["Color Mode", "Context", "Padding", "Page type", "Slot gap"],
|
|
400
|
+
"Popup": ["Color Mode", "Context", "Padding", "Page type", "Slot gap", "Stack Context"],
|
|
397
401
|
"PortfolioHero": ["Avatar Size", "Badge Size", "Color Mode", "context 10", "Context3", "Context4", "Profile Card Appearance"],
|
|
398
402
|
"ProductLabel": ["Avatar Size", "Badge Size", "Color Mode", "context 10", "Context4", "Profile Card Appearance"],
|
|
399
|
-
"ProductMerchandisingCard": ["AppearanceBrand", "AppearanceSystem", "Avatar Size", "Badge Size", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "Context4", "Emphasis", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
403
|
+
"ProductMerchandisingCard": ["AppearanceBrand", "AppearanceSystem", "Avatar Size", "Badge Size", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "Context4", "Emphasis", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
400
404
|
"ProductOverview": ["Avatar Size", "Badge Size", "Color Mode", "context 10", "Context4", "Profile Card Appearance"],
|
|
401
405
|
"ProfileCard": ["AppearanceBrand", "AppearanceSystem", "Avatar Size", "Badge Size", "Color Mode", "Context", "context 10", "Context2", "Context4", "context5", "Emphasis", "Icon Capsule Size", "List Item Style", "ListItem State", "NavArrow Direction", "Page type", "Profile Card Appearance", "Selectable", "Semantic Intent", "Slot gap", "UPI Handle Image"],
|
|
402
406
|
"ProjectionMarker": ["Color Mode", "context 10", "Profile Card Appearance"],
|
|
@@ -418,10 +422,10 @@ export const FIGMA_COMPONENT_MODES: Record<string, readonly string[]> = {
|
|
|
418
422
|
"Step": ["Color Mode", "Step Status"],
|
|
419
423
|
"StepLabel": ["AppearanceBrand", "AppearanceSystem", "Color Mode", "Emphasis", "Semantic Intent"],
|
|
420
424
|
"SuggestiveSearch": ["Color Mode", "Dropdown Item State", "FormField States", "Status"],
|
|
421
|
-
"SummaryTile": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "Context2", "context5", "Emphasis", "List Item Style", "NavArrow Direction", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
425
|
+
"SummaryTile": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "Context2", "context5", "Emphasis", "List Item Style", "NavArrow Direction", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
422
426
|
"SupportText": ["Color Mode", "FormField States", "Status"],
|
|
423
427
|
"SupportTextIcon": ["Color Mode", "FormField States", "Status"],
|
|
424
|
-
"SwappableAmount": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Color Mode", "Context", "context 10", "Emphasis", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
428
|
+
"SwappableAmount": ["AppearanceBrand", "AppearanceSystem", "Button / Size", "Button / State", "Button Glass State", "Button type", "Color Mode", "Context", "context 10", "Emphasis", "Page type", "Profile Card Appearance", "Semantic Intent"],
|
|
425
429
|
"TabItem": ["Color Mode"],
|
|
426
430
|
"TestimonialsCard": ["Avatar Size", "Badge Size", "Color Mode", "context 10", "Context4", "Profile Card Appearance"],
|
|
427
431
|
"Text": ["Color Mode", "Context", "context 10", "Profile Card Appearance", "Text Appearance", "Text Sizes", "Weight"],
|
|
@@ -433,8 +437,8 @@ export const FIGMA_COMPONENT_MODES: Record<string, readonly string[]> = {
|
|
|
433
437
|
"TransactionBubble": ["Color Mode", "context 10", "Context2", "Context3", "context5", "List Item Style", "NavArrow Direction", "Page type", "Profile Card Appearance", "Transaction Status"],
|
|
434
438
|
"TransactionStatus": ["Transaction Status"],
|
|
435
439
|
"UpiHandle": ["Color Mode", "context 10", "Profile Card Appearance", "UPI Handle Image"],
|
|
436
|
-
"ValueBackMetric": ["AppearanceBrand", "
|
|
437
|
-
"VStack": ["Context", "Padding", "Page type", "Slot gap"],
|
|
440
|
+
"ValueBackMetric": ["AppearanceBrand", "Badge Size", "Color Mode", "Context", "context 10", "Context4", "Emphasis", "Page type", "Profile Card Appearance", "Semantic Intent", "Text Appearance", "Text Sizes", "Weight"],
|
|
441
|
+
"VStack": ["Context", "Padding", "Page type", "Slot gap", "Stack Context"],
|
|
438
442
|
};
|
|
439
443
|
|
|
440
444
|
/**
|
package/src/icons/registry.ts
CHANGED
package/D2C.md
DELETED
|
@@ -1,113 +0,0 @@
|
|
|
1
|
-
# D2C — Design to Code with jfs-components
|
|
2
|
-
|
|
3
|
-
Implement the supplied Figma design using the installed `jfs-components`
|
|
4
|
-
package. Follow all four stages in order.
|
|
5
|
-
|
|
6
|
-
## Input
|
|
7
|
-
|
|
8
|
-
Use the Figma URL supplied after `/D2C` or in the user's latest message. If no
|
|
9
|
-
Figma URL was supplied, ask for one before doing anything else.
|
|
10
|
-
|
|
11
|
-
## 1. Read the design
|
|
12
|
-
|
|
13
|
-
1. Call the Figma MCP `get_design_context` for the linked node.
|
|
14
|
-
2. Call `get_screenshot` for the same node. Keep it as the visual reference for
|
|
15
|
-
final QA.
|
|
16
|
-
3. Follow Code Connect mappings, design annotations, and provided assets. If
|
|
17
|
-
Figma supplies an image or SVG URL, use it directly; do not create a
|
|
18
|
-
placeholder or install an icon package.
|
|
19
|
-
|
|
20
|
-
If the Figma MCP is unavailable or cannot read the node, report the blocker and
|
|
21
|
-
stop. Do not recreate the design from the URL or from assumptions.
|
|
22
|
-
|
|
23
|
-
## 2. Extract and resolve explicit modes
|
|
24
|
-
|
|
25
|
-
From the consuming project's root, run:
|
|
26
|
-
|
|
27
|
-
```bash
|
|
28
|
-
npx jfs-extract-modes "<figma-url>" --out modes.json
|
|
29
|
-
```
|
|
30
|
-
|
|
31
|
-
The CLI automatically loads `FIGMA_ACCESS_TOKEN` from the project-root `.env`.
|
|
32
|
-
An already exported shell value takes precedence. The token only needs the
|
|
33
|
-
Figma `file_content:read` scope. Never print, log, or ask the user to paste the
|
|
34
|
-
token into chat.
|
|
35
|
-
|
|
36
|
-
If the token is missing, stop and direct the user to `[Open .env](.env)` and
|
|
37
|
-
add `FIGMA_ACCESS_TOKEN=` if needed. To create a token: in Figma's file browser,
|
|
38
|
-
open the account menu → **Settings** → **Security** → **Personal access
|
|
39
|
-
tokens** → **Generate new token**, choose an expiration, grant only
|
|
40
|
-
`file_content:read`, generate it, and copy it immediately into `.env`. Figma
|
|
41
|
-
shows the value only once. Use the
|
|
42
|
-
[official PAT documentation](https://developers.figma.com/docs/rest-api/personal-access-tokens/)
|
|
43
|
-
if the UI has changed. Never create or overwrite a token value yourself.
|
|
44
|
-
|
|
45
|
-
If the bin is unavailable in a nonstandard monorepo, run:
|
|
46
|
-
|
|
47
|
-
```bash
|
|
48
|
-
node node_modules/jfs-components/scripts/extract-figma-modes.js "<figma-url>" --out modes.json
|
|
49
|
-
```
|
|
50
|
-
|
|
51
|
-
Resolve the effective modes for each represented component as follows:
|
|
52
|
-
|
|
53
|
-
1. Start with `inheritedFromAncestors`, when present.
|
|
54
|
-
2. Find every `modes` entry whose `path` is the component's path or an ancestor
|
|
55
|
-
of it.
|
|
56
|
-
3. Merge those entries from root to leaf; deeper entries override inherited
|
|
57
|
-
values.
|
|
58
|
-
4. Match by layer name and position, using `nodeId` to disambiguate duplicate
|
|
59
|
-
names.
|
|
60
|
-
|
|
61
|
-
If `unresolved` is present, report every item and its exact `reason`, then stop
|
|
62
|
-
before implementation because mode fidelity cannot be guaranteed:
|
|
63
|
-
|
|
64
|
-
- `local collection` means the design uses a file-local collection that the
|
|
65
|
-
packaged library data cannot resolve.
|
|
66
|
-
- `key not in variables JSON` or `mode not in collection` means the packaged
|
|
67
|
-
design-token JSON is out of date.
|
|
68
|
-
|
|
69
|
-
Do not guess or silently omit an unresolved mode.
|
|
70
|
-
|
|
71
|
-
## 3. Implement
|
|
72
|
-
|
|
73
|
-
Before editing, inspect the installed package's exports/types and the consuming
|
|
74
|
-
app's existing screens. Reuse its file placement, navigation, styling, and
|
|
75
|
-
asset conventions. Never invent a `jfs-components` component or prop.
|
|
76
|
-
|
|
77
|
-
- Prefer mapped `jfs-components` over rebuilding them from primitives.
|
|
78
|
-
- Apply extracted collection/mode pairs exactly through each component's
|
|
79
|
-
`modes` prop.
|
|
80
|
-
- Put a mode on the closest code component that represents the reported Figma
|
|
81
|
-
layer or subtree. Preserve parent inheritance and child overrides; never
|
|
82
|
-
flatten a child override into its parent.
|
|
83
|
-
- Do not substitute similar-looking modes, remove apparently redundant modes,
|
|
84
|
-
or move modes between layers.
|
|
85
|
-
- Match Figma content, order, visibility, variants, spacing, and assets.
|
|
86
|
-
|
|
87
|
-
Run the consuming app's existing typecheck, tests, or build command relevant to
|
|
88
|
-
the changed screen and fix implementation errors.
|
|
89
|
-
|
|
90
|
-
## 4. Render and visually verify
|
|
91
|
-
|
|
92
|
-
Render the implemented screen on the target platform and capture it with the
|
|
93
|
-
available mobile or browser tooling. Compare it with the Figma screenshot for:
|
|
94
|
-
|
|
95
|
-
1. component size, variant, and emphasis;
|
|
96
|
-
2. color and appearance;
|
|
97
|
-
3. spacing, padding, alignment, and gaps;
|
|
98
|
-
4. text, wrapping, and truncation; and
|
|
99
|
-
5. icons, imagery, and layer visibility.
|
|
100
|
-
|
|
101
|
-
Fix every implementation-caused difference and capture the screen again.
|
|
102
|
-
Platform or environment differences that cannot be fixed in code, such as a
|
|
103
|
-
missing system font or renderer-specific antialiasing, must be identified
|
|
104
|
-
explicitly rather than hidden.
|
|
105
|
-
|
|
106
|
-
If no suitable render or screenshot tooling is available, do not claim visual
|
|
107
|
-
completion. Report what remains to be checked and give the exact manual run and
|
|
108
|
-
comparison steps.
|
|
109
|
-
|
|
110
|
-
## Completion report
|
|
111
|
-
|
|
112
|
-
Report the files changed, the effective modes applied to each component, the
|
|
113
|
-
validation commands and results, and the final visual comparison status.
|