@seed-design/figma 1.1.18 → 1.2.0
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/lib/codegen/index.d.ts +9 -1
- package/lib/codegen/index.d.ts.map +1 -1
- package/lib/codegen/targets/react/index.cjs +135 -133
- package/lib/codegen/targets/react/index.js +135 -133
- package/package.json +2 -2
- package/src/codegen/component-properties.ts +9 -1
- package/src/codegen/targets/react/component/handlers/list-item.ts +5 -5
- package/src/codegen/targets/react/component/handlers/menu-sheet.ts +14 -12
- package/src/codegen/targets/react/component/handlers/radiomark.ts +1 -1
- package/src/codegen/targets/react/component/handlers/switch.ts +1 -1
- package/src/codegen/targets/react/component/handlers/switchmark.ts +1 -1
- package/src/codegen/targets/react/component/handlers/tag-group.ts +17 -23
|
@@ -3194,7 +3194,7 @@ function handleSizeProp(size) {
|
|
|
3194
3194
|
}
|
|
3195
3195
|
}
|
|
3196
3196
|
|
|
3197
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
3197
|
+
const { createLocalSnippetElement: createLocalSnippetElement$z } = createLocalSnippetHelper("action-button");
|
|
3198
3198
|
const createActionButtonHandler = (ctx)=>defineComponentHandler(actionButton.key, ({ componentProperties: props })=>{
|
|
3199
3199
|
const states = props.State.value.split("-");
|
|
3200
3200
|
const { layout, children } = match(props.Layout.value).with("Icon Only", ()=>({
|
|
@@ -3235,7 +3235,7 @@ const createActionButtonHandler = (ctx)=>defineComponentHandler(actionButton.key
|
|
|
3235
3235
|
variant: camelCase(props.Variant.value),
|
|
3236
3236
|
layout
|
|
3237
3237
|
};
|
|
3238
|
-
return createLocalSnippetElement$
|
|
3238
|
+
return createLocalSnippetElement$z("ActionButton", commonProps, children);
|
|
3239
3239
|
});
|
|
3240
3240
|
const ACTION_BUTTON_GHOST_BUTTON_KEY = "ea69291fb4d76217419f3d9613ae16aadafb56a5";
|
|
3241
3241
|
const createActionButtonGhostHandler = (ctx)=>defineComponentHandler(ACTION_BUTTON_GHOST_BUTTON_KEY, (node)=>{
|
|
@@ -3293,10 +3293,10 @@ const createActionButtonGhostHandler = (ctx)=>defineComponentHandler(ACTION_BUTT
|
|
|
3293
3293
|
bleedY: "asPadding"
|
|
3294
3294
|
}
|
|
3295
3295
|
};
|
|
3296
|
-
return createLocalSnippetElement$
|
|
3296
|
+
return createLocalSnippetElement$z("ActionButton", commonProps, children);
|
|
3297
3297
|
});
|
|
3298
3298
|
|
|
3299
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
3299
|
+
const { createLocalSnippetElement: createLocalSnippetElement$y } = createLocalSnippetHelper("alert-dialog");
|
|
3300
3300
|
const { createLocalSnippetElement: createLocalSnippetElementTrigger$3 } = createLocalSnippetHelper("action-button");
|
|
3301
3301
|
const ALERT_DIALOG_FOOTER_KEY = "00b1b131d67edf2875a7a1df8dfa88098d7c04be";
|
|
3302
3302
|
const createAlertDialogHandler = (ctx)=>{
|
|
@@ -3304,18 +3304,18 @@ const createAlertDialogHandler = (ctx)=>{
|
|
|
3304
3304
|
const actionButtonGhostHandler = createActionButtonGhostHandler(ctx);
|
|
3305
3305
|
return defineComponentHandler(alertDialog.key, (node, traverse)=>{
|
|
3306
3306
|
const props = node.componentProperties;
|
|
3307
|
-
const alertDialogHeader = createLocalSnippetElement$
|
|
3307
|
+
const alertDialogHeader = createLocalSnippetElement$y("AlertDialogHeader", undefined, [
|
|
3308
3308
|
...props["Show Title#20361:14"].value ? [
|
|
3309
|
-
createLocalSnippetElement$
|
|
3309
|
+
createLocalSnippetElement$y("AlertDialogTitle", undefined, props["Title Text#20361:0"].value)
|
|
3310
3310
|
] : [],
|
|
3311
|
-
createLocalSnippetElement$
|
|
3311
|
+
createLocalSnippetElement$y("AlertDialogDescription", undefined, props["Description Text#20361:7"].value)
|
|
3312
3312
|
]);
|
|
3313
3313
|
const footerNodes = findAllInstances({
|
|
3314
3314
|
node,
|
|
3315
3315
|
key: ALERT_DIALOG_FOOTER_KEY
|
|
3316
3316
|
});
|
|
3317
3317
|
if (footerNodes.length === 0 || footerNodes.length > 1) {
|
|
3318
|
-
return createLocalSnippetElement$
|
|
3318
|
+
return createLocalSnippetElement$y("AlertDialog", undefined, alertDialogHeader, {
|
|
3319
3319
|
comment: "Footer 영역을 확인해주세요."
|
|
3320
3320
|
});
|
|
3321
3321
|
}
|
|
@@ -3346,14 +3346,14 @@ const createAlertDialogHandler = (ctx)=>{
|
|
|
3346
3346
|
];
|
|
3347
3347
|
return createSeedReactElement("VStack", footerNodeProps, buttons);
|
|
3348
3348
|
}).exhaustive();
|
|
3349
|
-
const alertDialogFooter = createLocalSnippetElement$
|
|
3350
|
-
return createLocalSnippetElement$
|
|
3349
|
+
const alertDialogFooter = createLocalSnippetElement$y("AlertDialogFooter", undefined, alertDialogFooterChildren);
|
|
3350
|
+
return createLocalSnippetElement$y("AlertDialogRoot", {
|
|
3351
3351
|
open: true
|
|
3352
3352
|
}, [
|
|
3353
|
-
createLocalSnippetElement$
|
|
3353
|
+
createLocalSnippetElement$y("AlertDialogTrigger", {
|
|
3354
3354
|
asChild: true
|
|
3355
3355
|
}, createLocalSnippetElementTrigger$3("ActionButton", {}, "AlertDialog 열기")),
|
|
3356
|
-
createLocalSnippetElement$
|
|
3356
|
+
createLocalSnippetElement$y("AlertDialogContent", undefined, [
|
|
3357
3357
|
alertDialogHeader,
|
|
3358
3358
|
alertDialogFooter
|
|
3359
3359
|
])
|
|
@@ -3361,7 +3361,7 @@ const createAlertDialogHandler = (ctx)=>{
|
|
|
3361
3361
|
});
|
|
3362
3362
|
};
|
|
3363
3363
|
|
|
3364
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
3364
|
+
const { createLocalSnippetElement: createLocalSnippetElement$x } = createLocalSnippetHelper("app-bar");
|
|
3365
3365
|
const APP_BAR_TITLE_KEY = "d2cc4f615b2b44098be89448ad1c573f94af0355";
|
|
3366
3366
|
const APP_BAR_LEFT_ICON_BUTTON_KEY = "5a953f7bafc0df744777517458396e9f6c915825";
|
|
3367
3367
|
const APP_BAR_RIGHT_ICON_BUTTON_KEY = "c08db793288077e53bd45ef11aa419a835e88fce";
|
|
@@ -3378,12 +3378,12 @@ const createAppBarMainHandler = (_ctx)=>{
|
|
|
3378
3378
|
subtitle: undefined
|
|
3379
3379
|
})).exhaustive();
|
|
3380
3380
|
if (title) {
|
|
3381
|
-
return createLocalSnippetElement$
|
|
3381
|
+
return createLocalSnippetElement$x("AppBarMain", {
|
|
3382
3382
|
title,
|
|
3383
3383
|
subtitle
|
|
3384
3384
|
});
|
|
3385
3385
|
}
|
|
3386
|
-
return createLocalSnippetElement$
|
|
3386
|
+
return createLocalSnippetElement$x("AppBarMain", undefined, undefined, {
|
|
3387
3387
|
comment: "AppBarMain 내부를 직접 작성해주세요."
|
|
3388
3388
|
});
|
|
3389
3389
|
});
|
|
@@ -3410,33 +3410,33 @@ const createAppBarHandler = (ctx)=>{
|
|
|
3410
3410
|
return appBarMainHandler.transform(mainNode, traverse);
|
|
3411
3411
|
})();
|
|
3412
3412
|
const leftChildren = match(props.Left.value).with("None", ()=>undefined).with("Back", ()=>[
|
|
3413
|
-
createLocalSnippetElement$
|
|
3413
|
+
createLocalSnippetElement$x("AppBarBackButton")
|
|
3414
3414
|
]).with("Close", ()=>[
|
|
3415
|
-
createLocalSnippetElement$
|
|
3415
|
+
createLocalSnippetElement$x("AppBarCloseButton")
|
|
3416
3416
|
]).with("Custom", ()=>{
|
|
3417
3417
|
const buttons = findAllInstances({
|
|
3418
3418
|
node,
|
|
3419
3419
|
key: APP_BAR_LEFT_ICON_BUTTON_KEY
|
|
3420
3420
|
});
|
|
3421
3421
|
if (buttons.length > 0) {
|
|
3422
|
-
return buttons.map((button)=>createLocalSnippetElement$
|
|
3422
|
+
return buttons.map((button)=>createLocalSnippetElement$x("AppBarIconButton", undefined, ctx.iconHandler.transform(button.componentProperties["Icon#33580:0"]), {
|
|
3423
3423
|
comment: "AppBarIconButton에 aria-label 속성을 추가해주세요."
|
|
3424
3424
|
}));
|
|
3425
3425
|
}
|
|
3426
3426
|
return undefined;
|
|
3427
3427
|
}).exhaustive();
|
|
3428
|
-
const left = leftChildren && leftChildren.length > 0 ? createLocalSnippetElement$
|
|
3428
|
+
const left = leftChildren && leftChildren.length > 0 ? createLocalSnippetElement$x("AppBarLeft", {}, leftChildren) : undefined;
|
|
3429
3429
|
const rightChildren = match(props.Right.value).with("None", ()=>undefined).with("1 Icon Button", "2 Icon Button", "3 Icon Button", ()=>{
|
|
3430
3430
|
const buttons = findAllInstances({
|
|
3431
3431
|
node,
|
|
3432
3432
|
key: APP_BAR_RIGHT_ICON_BUTTON_KEY
|
|
3433
3433
|
});
|
|
3434
|
-
return buttons.map((button)=>createLocalSnippetElement$
|
|
3434
|
+
return buttons.map((button)=>createLocalSnippetElement$x("AppBarIconButton", undefined, ctx.iconHandler.transform(button.componentProperties["Icon#6406:3"]), {
|
|
3435
3435
|
comment: "AppBarIconButton에 aria-label 속성을 추가해주세요."
|
|
3436
3436
|
}));
|
|
3437
3437
|
}).with("Text Button", ()=>undefined).exhaustive();
|
|
3438
|
-
const right = rightChildren && rightChildren.length > 0 ? createLocalSnippetElement$
|
|
3439
|
-
return createLocalSnippetElement$
|
|
3438
|
+
const right = rightChildren && rightChildren.length > 0 ? createLocalSnippetElement$x("AppBarRight", {}, rightChildren) : undefined;
|
|
3439
|
+
return createLocalSnippetElement$x("AppBar", {
|
|
3440
3440
|
theme,
|
|
3441
3441
|
tone
|
|
3442
3442
|
}, [
|
|
@@ -3450,15 +3450,15 @@ const createAppBarHandler = (ctx)=>{
|
|
|
3450
3450
|
};
|
|
3451
3451
|
|
|
3452
3452
|
const IDENTITY_PLACEHOLDER_KEY = "b3563b6f16ba4cfe4240c9b33eef7edad4c304eb";
|
|
3453
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
3453
|
+
const { createLocalSnippetElement: createLocalSnippetElement$w } = createLocalSnippetHelper("identity-placeholder");
|
|
3454
3454
|
const createIdentityPlaceholderHandler = (_ctx)=>defineComponentHandler(IDENTITY_PLACEHOLDER_KEY, ({ componentProperties: props })=>{
|
|
3455
3455
|
const commonProps = {
|
|
3456
3456
|
identity: camelCase(props.Identity.value)
|
|
3457
3457
|
};
|
|
3458
|
-
return createLocalSnippetElement$
|
|
3458
|
+
return createLocalSnippetElement$w("IdentityPlaceholder", commonProps);
|
|
3459
3459
|
});
|
|
3460
3460
|
|
|
3461
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
3461
|
+
const { createLocalSnippetElement: createLocalSnippetElement$v } = createLocalSnippetHelper("avatar");
|
|
3462
3462
|
const createAvatarHandler = (ctx)=>{
|
|
3463
3463
|
const identityPlaceholderHandler = createIdentityPlaceholderHandler();
|
|
3464
3464
|
return defineComponentHandler(avatar.key, (node, traverse)=>{
|
|
@@ -3481,7 +3481,7 @@ const createAvatarHandler = (ctx)=>{
|
|
|
3481
3481
|
},
|
|
3482
3482
|
size: props.Size.value
|
|
3483
3483
|
};
|
|
3484
|
-
return createLocalSnippetElement$
|
|
3484
|
+
return createLocalSnippetElement$v("Avatar", commonProps, props["Badge"].value === "None" ? undefined : createLocalSnippetElement$v("AvatarBadge", {
|
|
3485
3485
|
asChild: true
|
|
3486
3486
|
}, createElement("img", {
|
|
3487
3487
|
src: "https://placehold.co/20x20"
|
|
@@ -3493,7 +3493,7 @@ const createAvatarHandler = (ctx)=>{
|
|
|
3493
3493
|
});
|
|
3494
3494
|
};
|
|
3495
3495
|
|
|
3496
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
3496
|
+
const { createLocalSnippetElement: createLocalSnippetElement$u } = createLocalSnippetHelper("avatar");
|
|
3497
3497
|
const createAvatarStackHandler = (ctx)=>{
|
|
3498
3498
|
const avatarHandler = createAvatarHandler();
|
|
3499
3499
|
return defineComponentHandler(avatarStack.key, (node, traverse)=>{
|
|
@@ -3506,7 +3506,7 @@ const createAvatarStackHandler = (ctx)=>{
|
|
|
3506
3506
|
size: props.Size.value
|
|
3507
3507
|
};
|
|
3508
3508
|
const avatarStackChildren = avatarNodes.map((avatarNode)=>avatarHandler.transform(avatarNode, traverse));
|
|
3509
|
-
return createLocalSnippetElement$
|
|
3509
|
+
return createLocalSnippetElement$u("AvatarStack", commonProps, avatarStackChildren);
|
|
3510
3510
|
});
|
|
3511
3511
|
};
|
|
3512
3512
|
|
|
@@ -3519,7 +3519,7 @@ const createBadgeHandler = (_ctx)=>defineComponentHandler(badge.key, ({ componen
|
|
|
3519
3519
|
return createSeedReactElement("Badge", commonProps, props["Label#1584:0"].value);
|
|
3520
3520
|
});
|
|
3521
3521
|
|
|
3522
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
3522
|
+
const { createLocalSnippetElement: createLocalSnippetElement$t } = createLocalSnippetHelper("bottom-sheet");
|
|
3523
3523
|
const { createLocalSnippetElement: createLocalSnippetElementTrigger$2 } = createLocalSnippetHelper("action-button");
|
|
3524
3524
|
// TODO: Bottom Action Bar (WIP) handler의 키. 해당 컴포넌트(템플릿) 핸들러 작성 시 handler.transform()으로 대체
|
|
3525
3525
|
const BOTTOM_SHEET_FOOTER_KEY = "de6c65d34cc4a01c18c9a7c0ded34635170ca11f";
|
|
@@ -3539,32 +3539,32 @@ const createBottomSheetHandler = (_ctx)=>defineComponentHandler(bottomSheet.key,
|
|
|
3539
3539
|
node,
|
|
3540
3540
|
key: BOTTOM_SHEET_BODY_KEY
|
|
3541
3541
|
});
|
|
3542
|
-
const bottomSheetBody = bodyNodes.length === 1 ? createLocalSnippetElement$
|
|
3542
|
+
const bottomSheetBody = bodyNodes.length === 1 ? createLocalSnippetElement$t("BottomSheetBody", {}, bodyNodes[0].children.map(traverse)) : createLocalSnippetElement$t("BottomSheetBody", {}, createElement("div", undefined, "No content available"));
|
|
3543
3543
|
const footerNodes = findAllInstances({
|
|
3544
3544
|
node,
|
|
3545
3545
|
key: BOTTOM_SHEET_FOOTER_KEY
|
|
3546
3546
|
});
|
|
3547
|
-
const bottomSheetFooter = props["Show Footer#25162:14"] && footerNodes.length === 1 ? createLocalSnippetElement$
|
|
3548
|
-
return createLocalSnippetElement$
|
|
3547
|
+
const bottomSheetFooter = props["Show Footer#25162:14"] && footerNodes.length === 1 ? createLocalSnippetElement$t("BottomSheetFooter", {}, footerNodes[0].children.map(traverse)) : undefined;
|
|
3548
|
+
return createLocalSnippetElement$t("BottomSheetRoot", {
|
|
3549
3549
|
defaultOpen: true,
|
|
3550
3550
|
headerAlign
|
|
3551
3551
|
}, [
|
|
3552
|
-
createLocalSnippetElement$
|
|
3552
|
+
createLocalSnippetElement$t("BottomSheetTrigger", {
|
|
3553
3553
|
asChild: true
|
|
3554
3554
|
}, createLocalSnippetElementTrigger$2("ActionButton", {}, "BottomSheet 열기")),
|
|
3555
|
-
createLocalSnippetElement$
|
|
3555
|
+
createLocalSnippetElement$t("BottomSheetContent", contentProps, [
|
|
3556
3556
|
bottomSheetBody,
|
|
3557
3557
|
bottomSheetFooter
|
|
3558
3558
|
])
|
|
3559
3559
|
]);
|
|
3560
3560
|
});
|
|
3561
3561
|
|
|
3562
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
3562
|
+
const { createLocalSnippetElement: createLocalSnippetElement$s } = createLocalSnippetHelper("callout");
|
|
3563
3563
|
const createCalloutHandler = (ctx)=>defineComponentHandler(callout.key, ({ componentProperties: props, children })=>{
|
|
3564
3564
|
const tag = match(props.Interaction.value).with("Display", ()=>"Callout").with("Actionable", ()=>"ActionableCallout").with("Dismissible", ()=>"DismissibleCallout").exhaustive();
|
|
3565
3565
|
const textNode = children.find((child)=>child.type === "TEXT");
|
|
3566
3566
|
if (!textNode) {
|
|
3567
|
-
return createLocalSnippetElement$
|
|
3567
|
+
return createLocalSnippetElement$s(tag, undefined, undefined, {
|
|
3568
3568
|
comment: "내용을 제공해주세요."
|
|
3569
3569
|
});
|
|
3570
3570
|
}
|
|
@@ -3616,10 +3616,10 @@ const createCalloutHandler = (ctx)=>defineComponentHandler(callout.key, ({ compo
|
|
|
3616
3616
|
prefixIcon: ctx.iconHandler.transform(props["Prefix Icon#35087:0"])
|
|
3617
3617
|
}
|
|
3618
3618
|
};
|
|
3619
|
-
return createLocalSnippetElement$
|
|
3619
|
+
return createLocalSnippetElement$s(tag, commonProps);
|
|
3620
3620
|
});
|
|
3621
3621
|
|
|
3622
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
3622
|
+
const { createLocalSnippetElement: createLocalSnippetElement$r } = createLocalSnippetHelper("checkbox");
|
|
3623
3623
|
const createCheckboxHandler = (_ctx)=>defineComponentHandler(checkbox.key, ({ componentProperties: props })=>{
|
|
3624
3624
|
const tone = match(props.Tone.value).with("Neutral", ()=>"neutral").with("🚫[Deprecated]Brand", ()=>"brand").exhaustive();
|
|
3625
3625
|
const commonProps = {
|
|
@@ -3639,10 +3639,10 @@ const createCheckboxHandler = (_ctx)=>defineComponentHandler(checkbox.key, ({ co
|
|
|
3639
3639
|
disabled: true
|
|
3640
3640
|
}
|
|
3641
3641
|
};
|
|
3642
|
-
return createLocalSnippetElement$
|
|
3642
|
+
return createLocalSnippetElement$r("Checkbox", commonProps);
|
|
3643
3643
|
});
|
|
3644
3644
|
|
|
3645
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
3645
|
+
const { createLocalSnippetElement: createLocalSnippetElement$q } = createLocalSnippetHelper("checkbox");
|
|
3646
3646
|
const createCheckmarkHandler = (_ctx)=>defineComponentHandler(checkmark.key, ({ componentProperties: props })=>{
|
|
3647
3647
|
const tone = match(props.Tone.value).with("Neutral", ()=>"neutral").with("🚫[Deprecated]Brand", ()=>"brand").exhaustive();
|
|
3648
3648
|
const commonProps = {
|
|
@@ -3650,14 +3650,14 @@ const createCheckmarkHandler = (_ctx)=>defineComponentHandler(checkmark.key, ({
|
|
|
3650
3650
|
variant: camelCase(props.Shape.value),
|
|
3651
3651
|
size: handleSizeProp(props.Size.value)
|
|
3652
3652
|
};
|
|
3653
|
-
return createLocalSnippetElement$
|
|
3653
|
+
return createLocalSnippetElement$q("Checkmark", commonProps);
|
|
3654
3654
|
});
|
|
3655
3655
|
|
|
3656
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
3656
|
+
const { createLocalSnippetElement: createLocalSnippetElement$p } = createLocalSnippetHelper("chip");
|
|
3657
3657
|
const CHIP_ICON_SUFFIX_KEY = "27343e0e5ab2c66948e9b10fde03d58b5e037212";
|
|
3658
3658
|
const createChipIconSuffixHandler = (ctx)=>{
|
|
3659
3659
|
return defineComponentHandler(CHIP_ICON_SUFFIX_KEY, ({ componentProperties })=>{
|
|
3660
|
-
return createLocalSnippetElement$
|
|
3660
|
+
return createLocalSnippetElement$p("Chip.SuffixIcon", undefined, createSeedReactElement("Icon", {
|
|
3661
3661
|
svg: ctx.iconHandler.transform(componentProperties["Icon#33203:0"])
|
|
3662
3662
|
}));
|
|
3663
3663
|
});
|
|
@@ -3667,7 +3667,7 @@ const createChipHandler = (ctx)=>{
|
|
|
3667
3667
|
const iconSuffixHandler = createChipIconSuffixHandler(ctx);
|
|
3668
3668
|
return defineComponentHandler(chip.key, (node, traverse)=>{
|
|
3669
3669
|
const props = node.componentProperties;
|
|
3670
|
-
const prefix = match(props["Prefix Type"].value).with("None", "Image", ()=>undefined).with("Icon", ()=>createLocalSnippetElement$
|
|
3670
|
+
const prefix = match(props["Prefix Type"].value).with("None", "Image", ()=>undefined).with("Icon", ()=>createLocalSnippetElement$p("Chip.PrefixIcon", undefined, createSeedReactElement("Icon", {
|
|
3671
3671
|
svg: ctx.iconHandler.transform(props["Prefix Icon#8722:0"])
|
|
3672
3672
|
}))).with("Avatar", ()=>{
|
|
3673
3673
|
const [avatar$1] = findAllInstances({
|
|
@@ -3675,9 +3675,9 @@ const createChipHandler = (ctx)=>{
|
|
|
3675
3675
|
key: avatar.key
|
|
3676
3676
|
});
|
|
3677
3677
|
if (!avatar$1) return undefined;
|
|
3678
|
-
return createLocalSnippetElement$
|
|
3678
|
+
return createLocalSnippetElement$p("Chip.PrefixAvatar", undefined, avatarHandler.transform(avatar$1, traverse));
|
|
3679
3679
|
}).exhaustive();
|
|
3680
|
-
const label = createLocalSnippetElement$
|
|
3680
|
+
const label = createLocalSnippetElement$p("Chip.Label", undefined, props["Label#7185:0"].value);
|
|
3681
3681
|
const [suffixIcon] = findAllInstances({
|
|
3682
3682
|
node,
|
|
3683
3683
|
key: CHIP_ICON_SUFFIX_KEY
|
|
@@ -3693,7 +3693,7 @@ const createChipHandler = (ctx)=>{
|
|
|
3693
3693
|
disabled: true
|
|
3694
3694
|
}
|
|
3695
3695
|
};
|
|
3696
|
-
return createLocalSnippetElement$
|
|
3696
|
+
return createLocalSnippetElement$p("Chip.Toggle", commonProps, [
|
|
3697
3697
|
prefix,
|
|
3698
3698
|
label,
|
|
3699
3699
|
suffixIcon ? iconSuffixHandler.transform(suffixIcon, traverse) : undefined
|
|
@@ -3703,7 +3703,7 @@ const createChipHandler = (ctx)=>{
|
|
|
3703
3703
|
});
|
|
3704
3704
|
};
|
|
3705
3705
|
|
|
3706
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
3706
|
+
const { createLocalSnippetElement: createLocalSnippetElement$o } = createLocalSnippetHelper("contextual-floating-button");
|
|
3707
3707
|
const createContextualFloatingButtonHandler = (ctx)=>defineComponentHandler(contextualFloatingButton.key, ({ componentProperties: props })=>{
|
|
3708
3708
|
const states = props.State.value.split("-");
|
|
3709
3709
|
const { layout, children } = match(props.Layout.value).with("Icon Only", ()=>({
|
|
@@ -3732,7 +3732,7 @@ const createContextualFloatingButtonHandler = (ctx)=>defineComponentHandler(cont
|
|
|
3732
3732
|
variant: match(props.Variant.value).with("Solid", ()=>"solid").with("Layer", ()=>"layer").exhaustive(),
|
|
3733
3733
|
layout
|
|
3734
3734
|
};
|
|
3735
|
-
return createLocalSnippetElement$
|
|
3735
|
+
return createLocalSnippetElement$o("ContextualFloatingButton", commonProps, children);
|
|
3736
3736
|
});
|
|
3737
3737
|
|
|
3738
3738
|
const createDividerHandler = (_ctx)=>defineComponentHandler(divider.key, ({ componentProperties: props })=>{
|
|
@@ -3857,7 +3857,7 @@ const FIELD_KEYS = {
|
|
|
3857
3857
|
});
|
|
3858
3858
|
};
|
|
3859
3859
|
|
|
3860
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
3860
|
+
const { createLocalSnippetElement: createLocalSnippetElement$n } = createLocalSnippetHelper("field-button");
|
|
3861
3861
|
const INPUT_BUTTON_KEY = "965bdecb58755af9a08d60cc3c8d2d33b42e15f0";
|
|
3862
3862
|
const INPUT_BUTTON_PREFIX_KEY = "12b40c736a098298c64ba16de85702b4b460d1f1";
|
|
3863
3863
|
const INPUT_BUTTON_SUFFIX_KEY = "5dda27af9f4afafa471925c17acf97d81912877a";
|
|
@@ -3916,11 +3916,11 @@ const createFieldButtonHandler = (ctx)=>{
|
|
|
3916
3916
|
// these can be fragile but better than having 9 different handlers
|
|
3917
3917
|
const placeholder = findOne(node, (node)=>node.type === "TEXT" && node.name.toLowerCase().includes("placeholder"));
|
|
3918
3918
|
const value = findOne(node, (node)=>node.type === "TEXT" && node.name.toLowerCase().includes("value"));
|
|
3919
|
-
return createLocalSnippetElement$
|
|
3919
|
+
return createLocalSnippetElement$n("FieldButton", {
|
|
3920
3920
|
...headerProps,
|
|
3921
3921
|
...footerProps,
|
|
3922
3922
|
...commonProps
|
|
3923
|
-
}, props["Has Value"].value === "True" && value ? createLocalSnippetElement$
|
|
3923
|
+
}, props["Has Value"].value === "True" && value ? createLocalSnippetElement$n("FieldButtonValue", undefined, value.characters) : placeholder ? createLocalSnippetElement$n("FieldButtonPlaceholder", undefined, placeholder.characters) : undefined, {
|
|
3924
3924
|
comment: "buttonProps를 통해 aria-label을 제공하세요."
|
|
3925
3925
|
});
|
|
3926
3926
|
});
|
|
@@ -3967,7 +3967,7 @@ const createAddressFieldHandler = (ctx)=>{
|
|
|
3967
3967
|
});
|
|
3968
3968
|
};
|
|
3969
3969
|
|
|
3970
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
3970
|
+
const { createLocalSnippetElement: createLocalSnippetElement$m } = createLocalSnippetHelper("floating-action-button");
|
|
3971
3971
|
const BUTTON_TYPE_KEY = "8cecc85275115d653579d4c3156567ebf19f7b27";
|
|
3972
3972
|
const MENU_TYPE_KEY = "400124347392c15473f9cd2d8a6aedb64f3baf36";
|
|
3973
3973
|
const createFloatingActionButtonHandler = (ctx)=>defineComponentHandler(floatingActionButton.key, (node)=>{
|
|
@@ -3991,10 +3991,10 @@ const createFloatingActionButtonHandler = (ctx)=>defineComponentHandler(floating
|
|
|
3991
3991
|
label: menu.componentProperties["Label#29766:9"].value
|
|
3992
3992
|
};
|
|
3993
3993
|
})();
|
|
3994
|
-
return createLocalSnippetElement$
|
|
3994
|
+
return createLocalSnippetElement$m("FloatingActionButton", commonProps);
|
|
3995
3995
|
});
|
|
3996
3996
|
|
|
3997
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
3997
|
+
const { createLocalSnippetElement: createLocalSnippetElement$l } = createLocalSnippetHelper("help-bubble");
|
|
3998
3998
|
const { createLocalSnippetElement: createLocalSnippetElementTrigger$1 } = createLocalSnippetHelper("action-button");
|
|
3999
3999
|
const createHelpBubbleHandler = (_ctx)=>defineComponentHandler(helpBubble.key, ({ componentProperties: props })=>{
|
|
4000
4000
|
const placement = (()=>{
|
|
@@ -4034,23 +4034,23 @@ const createHelpBubbleHandler = (_ctx)=>defineComponentHandler(helpBubble.key, (
|
|
|
4034
4034
|
showCloseButton: props["Show Close Button#40538:0"].value,
|
|
4035
4035
|
placement
|
|
4036
4036
|
};
|
|
4037
|
-
return createLocalSnippetElement$
|
|
4037
|
+
return createLocalSnippetElement$l("HelpBubbleTrigger", commonProps, createLocalSnippetElementTrigger$1("ActionButton", {}, "HelpBubble 열기"), {
|
|
4038
4038
|
comment: "필요에 따라 HelpBubbleAnchor로 변경하여 사용하세요."
|
|
4039
4039
|
});
|
|
4040
4040
|
});
|
|
4041
4041
|
|
|
4042
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4042
|
+
const { createLocalSnippetElement: createLocalSnippetElement$k } = createLocalSnippetHelper("list-header");
|
|
4043
4043
|
const createListHeaderHandler = (_ctx)=>defineComponentHandler(listHeader.key, ({ componentProperties: props })=>{
|
|
4044
4044
|
const commonProps = {
|
|
4045
4045
|
variant: camelCase(props["Variant"].value)
|
|
4046
4046
|
};
|
|
4047
|
-
return createLocalSnippetElement$
|
|
4047
|
+
return createLocalSnippetElement$k("ListHeader", commonProps, props["Title#28588:0"].value);
|
|
4048
4048
|
});
|
|
4049
4049
|
|
|
4050
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4050
|
+
const { createLocalSnippetElement: createLocalSnippetElement$j } = createLocalSnippetHelper("list");
|
|
4051
4051
|
const PREFIX_KEYS = {
|
|
4052
4052
|
checkmark: "f24c9ef42ef08df79483fbae0fa7d9037e566748",
|
|
4053
|
-
|
|
4053
|
+
radiomark: "5a77ad37a2291989dfe77c44ddee9aa39e447f90",
|
|
4054
4054
|
icon: "0e4c05f097d3fa2dc0cbfdbf8db2662bcf8439ca",
|
|
4055
4055
|
avatar: "ef0e8bd6c2f92e620acf204bb9a8079ef25a1e5c",
|
|
4056
4056
|
image: "82239325aa1cb65af7c649fc71a8f2b48fb9b9f3",
|
|
@@ -4058,7 +4058,7 @@ const PREFIX_KEYS = {
|
|
|
4058
4058
|
};
|
|
4059
4059
|
const SUFFIX_KEYS = {
|
|
4060
4060
|
checkmark: "abf9810103ae6e6afe8fa253ec5f05d6a7304b38",
|
|
4061
|
-
|
|
4061
|
+
radiomark: "0a9464ad270bfd7f56438f62bb0155a25ca146a9",
|
|
4062
4062
|
chevron: "8c52207687ffed15cd5931d71ed9d196b3358a68",
|
|
4063
4063
|
switch: "1e933f75dd6bb4b21c3289b5c3b4402d2c623125",
|
|
4064
4064
|
custom: "3a70bf5bb9856c13893931b7a0df652bcf0be895",
|
|
@@ -4119,16 +4119,16 @@ const createListItemHandler = (ctx)=>defineComponentHandler(listItem.key, (node,
|
|
|
4119
4119
|
})();
|
|
4120
4120
|
const disabled = props.State.value === "Disabled";
|
|
4121
4121
|
const tag = (()=>{
|
|
4122
|
-
if (suffix?.tag === "
|
|
4122
|
+
if (suffix?.tag === "Switchmark") {
|
|
4123
4123
|
return "ListSwitchItem";
|
|
4124
4124
|
}
|
|
4125
4125
|
if (prefix?.tag === "Checkmark" || suffix?.tag === "Checkmark") {
|
|
4126
4126
|
return "ListCheckItem";
|
|
4127
4127
|
}
|
|
4128
|
-
if (prefix?.tag === "
|
|
4128
|
+
if (prefix?.tag === "Radiomark" || suffix?.tag === "Radiomark") {
|
|
4129
4129
|
return "ListRadioItem";
|
|
4130
4130
|
}
|
|
4131
|
-
// checkmark/
|
|
4131
|
+
// checkmark/radiomark 없는데 disabled인 경우 Button으로 추측
|
|
4132
4132
|
if (disabled) {
|
|
4133
4133
|
return "ListButtonItem";
|
|
4134
4134
|
}
|
|
@@ -4157,37 +4157,37 @@ const createListItemHandler = (ctx)=>defineComponentHandler(listItem.key, (node,
|
|
|
4157
4157
|
}
|
|
4158
4158
|
};
|
|
4159
4159
|
const comment = match(tag).with("ListItem", ()=>"목적에 따라 ListButtonItem이나 ListLinkItem으로 바꿔 사용하세요.").with("ListCheckItem", ()=>`<List as="fieldset">과 함께 사용하세요.`).with("ListRadioItem", ()=>"<RadioGroup.Root>와 함께 사용하세요.").otherwise(()=>undefined);
|
|
4160
|
-
const list = createLocalSnippetElement$
|
|
4160
|
+
const list = createLocalSnippetElement$j(tag, commonProps, undefined, {
|
|
4161
4161
|
comment
|
|
4162
4162
|
});
|
|
4163
4163
|
if (props["Divider#28441:0"].value) {
|
|
4164
4164
|
return createElement("", {}, [
|
|
4165
4165
|
list,
|
|
4166
|
-
createLocalSnippetElement$
|
|
4166
|
+
createLocalSnippetElement$j("ListDivider")
|
|
4167
4167
|
]);
|
|
4168
4168
|
}
|
|
4169
4169
|
return list;
|
|
4170
4170
|
});
|
|
4171
4171
|
|
|
4172
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4172
|
+
const { createLocalSnippetElement: createLocalSnippetElement$i } = createLocalSnippetHelper("manner-temp-badge");
|
|
4173
4173
|
const createMannerTempBadgeHandler = (_ctx)=>defineComponentHandler(mannerTempBadge.key, ({ children })=>{
|
|
4174
4174
|
const textNode = children.find((child)=>child.type === "TEXT");
|
|
4175
4175
|
const commonProps = {
|
|
4176
4176
|
temperature: Number(textNode?.characters.replace(/[^\d.-]/g, "") ?? "-1")
|
|
4177
4177
|
};
|
|
4178
|
-
return createLocalSnippetElement$
|
|
4178
|
+
return createLocalSnippetElement$i("MannerTempBadge", commonProps);
|
|
4179
4179
|
});
|
|
4180
4180
|
|
|
4181
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4181
|
+
const { createLocalSnippetElement: createLocalSnippetElement$h } = createLocalSnippetHelper("manner-temp");
|
|
4182
4182
|
const createMannerTempHandler = (_ctx)=>defineComponentHandler(mannerTemp.key, ({ children })=>{
|
|
4183
4183
|
const textNode = children.find((child)=>child.type === "TEXT");
|
|
4184
4184
|
const commonProps = {
|
|
4185
4185
|
temperature: Number(textNode?.characters.replace(/[^\d.-]/g, "") ?? "-1")
|
|
4186
4186
|
};
|
|
4187
|
-
return createLocalSnippetElement$
|
|
4187
|
+
return createLocalSnippetElement$h("MannerTemp", commonProps);
|
|
4188
4188
|
});
|
|
4189
4189
|
|
|
4190
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4190
|
+
const { createLocalSnippetElement: createLocalSnippetElement$g } = createLocalSnippetHelper("menu-sheet");
|
|
4191
4191
|
const { createLocalSnippetElement: createLocalSnippetElementTrigger } = createLocalSnippetHelper("action-button");
|
|
4192
4192
|
const MENU_SHEET_ITEM_KEY = "057083e95466da59051119eec0b41d4ad5a07f8f";
|
|
4193
4193
|
const createMenuSheetItemHandler = (ctx)=>defineComponentHandler(MENU_SHEET_ITEM_KEY, ({ componentProperties: props })=>{
|
|
@@ -4196,14 +4196,16 @@ const createMenuSheetItemHandler = (ctx)=>defineComponentHandler(MENU_SHEET_ITEM
|
|
|
4196
4196
|
tone: camelCase(props.Tone.value),
|
|
4197
4197
|
...states.includes("Disabled") && {
|
|
4198
4198
|
disabled: true
|
|
4199
|
+
},
|
|
4200
|
+
...props["Show Prefix Icon#17043:5"].value && {
|
|
4201
|
+
prefixIcon: ctx.iconHandler.transform(props["Prefix Icon#55948:0"])
|
|
4202
|
+
},
|
|
4203
|
+
label: props["Label#55905:8"].value,
|
|
4204
|
+
...props["Show Item Description#51411:19"].value && {
|
|
4205
|
+
description: props["Sub Text#51411:0"].value
|
|
4199
4206
|
}
|
|
4200
4207
|
};
|
|
4201
|
-
return createLocalSnippetElement$
|
|
4202
|
-
props["Show Prefix Icon#17043:5"].value ? createSeedReactElement("PrefixIcon", {
|
|
4203
|
-
svg: ctx.iconHandler.transform(props["Prefix Icon#55948:0"])
|
|
4204
|
-
}) : undefined,
|
|
4205
|
-
props["Label#55905:8"].value
|
|
4206
|
-
]);
|
|
4208
|
+
return createLocalSnippetElement$g("MenuSheetItem", commonProps);
|
|
4207
4209
|
});
|
|
4208
4210
|
const MENU_SHEET_GROUP_KEY = "2a504a1c6b7810d5e652862dcba2cb7048f9eb16";
|
|
4209
4211
|
const createMenuSheetGroupHandler = (ctx)=>{
|
|
@@ -4214,7 +4216,7 @@ const createMenuSheetGroupHandler = (ctx)=>{
|
|
|
4214
4216
|
key: menuSheetItemHandler.key
|
|
4215
4217
|
});
|
|
4216
4218
|
const contentChildren = items.map((item)=>menuSheetItemHandler.transform(item, traverse));
|
|
4217
|
-
return createLocalSnippetElement$
|
|
4219
|
+
return createLocalSnippetElement$g("MenuSheetGroup", undefined, contentChildren);
|
|
4218
4220
|
});
|
|
4219
4221
|
};
|
|
4220
4222
|
const createMenuSheetHandler = (ctx)=>{
|
|
@@ -4227,30 +4229,30 @@ const createMenuSheetHandler = (ctx)=>{
|
|
|
4227
4229
|
});
|
|
4228
4230
|
const contentChildren = groups.map((group)=>menuSheetGroupHandler.transform(group, traverse));
|
|
4229
4231
|
const title = props["Show Header#17043:12"].value ? props["Title Text#14599:0"].value : undefined;
|
|
4230
|
-
|
|
4231
|
-
// const description = props["Description Text#21827:0"].value;
|
|
4232
|
+
const description = props["Show Header#17043:12"].value && props["Show Header Description#32984:0"].value ? props["Description Text#21827:0"].value : undefined;
|
|
4232
4233
|
const { labelAlign } = match(props.Layout.value).with("Text with Icon", ()=>({
|
|
4233
4234
|
labelAlign: "left"
|
|
4234
4235
|
})).with("Text Only", ()=>({
|
|
4235
4236
|
labelAlign: "center"
|
|
4236
4237
|
})).exhaustive();
|
|
4237
|
-
const content = createLocalSnippetElement$
|
|
4238
|
+
const content = createLocalSnippetElement$g("MenuSheetContent", {
|
|
4238
4239
|
title,
|
|
4240
|
+
description,
|
|
4239
4241
|
labelAlign
|
|
4240
4242
|
}, contentChildren, {
|
|
4241
4243
|
comment: title ? undefined : "title을 제공하지 않는 경우 aria-label이나 aria-labelledby 중 하나를 제공해야 합니다."
|
|
4242
4244
|
});
|
|
4243
|
-
const trigger = createLocalSnippetElement$
|
|
4245
|
+
const trigger = createLocalSnippetElement$g("MenuSheetTrigger", {
|
|
4244
4246
|
asChild: true
|
|
4245
4247
|
}, createLocalSnippetElementTrigger("ActionButton", {}, "MenuSheet 열기"));
|
|
4246
|
-
return createLocalSnippetElement$
|
|
4248
|
+
return createLocalSnippetElement$g("MenuSheet", undefined, [
|
|
4247
4249
|
trigger,
|
|
4248
4250
|
content
|
|
4249
4251
|
]);
|
|
4250
4252
|
});
|
|
4251
4253
|
};
|
|
4252
4254
|
|
|
4253
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4255
|
+
const { createLocalSnippetElement: createLocalSnippetElement$f } = createLocalSnippetHelper("page-banner");
|
|
4254
4256
|
const SUFFIX_BUTTON_KEY = "7dce4e1242761ccd8e5da42278fc2d870918039c";
|
|
4255
4257
|
const createPageBannerButtonHandler = (_ctx)=>defineComponentHandler(SUFFIX_BUTTON_KEY, (node)=>{
|
|
4256
4258
|
return createElement("PageBannerButton", undefined, node.componentProperties["Label#39890:0"].value);
|
|
@@ -4284,7 +4286,7 @@ const createPageBannerHandler = (ctx)=>{
|
|
|
4284
4286
|
})).exhaustive();
|
|
4285
4287
|
const textNode = findOne(node, (child)=>child.type === "TEXT" && child.name === "Text");
|
|
4286
4288
|
if (!textNode) {
|
|
4287
|
-
return createLocalSnippetElement$
|
|
4289
|
+
return createLocalSnippetElement$f(tag, undefined, undefined, {
|
|
4288
4290
|
comment: "내용을 제공해주세요."
|
|
4289
4291
|
});
|
|
4290
4292
|
}
|
|
@@ -4317,11 +4319,11 @@ const createPageBannerHandler = (ctx)=>{
|
|
|
4317
4319
|
suffix
|
|
4318
4320
|
}
|
|
4319
4321
|
};
|
|
4320
|
-
return createLocalSnippetElement$
|
|
4322
|
+
return createLocalSnippetElement$f(tag, commonProps);
|
|
4321
4323
|
});
|
|
4322
4324
|
};
|
|
4323
4325
|
|
|
4324
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4326
|
+
const { createLocalSnippetElement: createLocalSnippetElement$e } = createLocalSnippetHelper("progress-circle");
|
|
4325
4327
|
const createProgressCircleHandler = (_ctx)=>defineComponentHandler(progressCircle.key, ({ componentProperties: props })=>{
|
|
4326
4328
|
const { value, minValue, maxValue } = match(props.Value.value).with("Indeterminate", ()=>({
|
|
4327
4329
|
value: undefined,
|
|
@@ -4353,10 +4355,10 @@ const createProgressCircleHandler = (_ctx)=>defineComponentHandler(progressCircl
|
|
|
4353
4355
|
tone: camelCase(props.Tone.value)
|
|
4354
4356
|
}
|
|
4355
4357
|
};
|
|
4356
|
-
return createLocalSnippetElement$
|
|
4358
|
+
return createLocalSnippetElement$e("ProgressCircle", commonProps);
|
|
4357
4359
|
});
|
|
4358
4360
|
|
|
4359
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4361
|
+
const { createLocalSnippetElement: createLocalSnippetElement$d } = createLocalSnippetHelper("radio-group");
|
|
4360
4362
|
const createRadioGroupItemHandler = (_ctx)=>defineComponentHandler(radio.key, ({ componentProperties: props })=>{
|
|
4361
4363
|
const tone = match(props.Tone.value).with("Neutral", ()=>"neutral").with("🚫[Deprecated]Brand", ()=>"brand").exhaustive();
|
|
4362
4364
|
const commonProps = {
|
|
@@ -4369,20 +4371,20 @@ const createRadioGroupItemHandler = (_ctx)=>defineComponentHandler(radio.key, ({
|
|
|
4369
4371
|
tone,
|
|
4370
4372
|
weight: camelCase(props.Weight.value)
|
|
4371
4373
|
};
|
|
4372
|
-
return createLocalSnippetElement$
|
|
4374
|
+
return createLocalSnippetElement$d("RadioGroupItem", commonProps);
|
|
4373
4375
|
});
|
|
4374
4376
|
|
|
4375
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4377
|
+
const { createLocalSnippetElement: createLocalSnippetElement$c } = createLocalSnippetHelper("radio-group");
|
|
4376
4378
|
const createRadiomarkHandler = (_ctx)=>defineComponentHandler(radiomark.key, ({ componentProperties: props })=>{
|
|
4377
4379
|
const tone = match(props.Tone.value).with("Neutral", ()=>"neutral").with("🚫[Deprecated]Brand", ()=>"brand").exhaustive();
|
|
4378
4380
|
const commonProps = {
|
|
4379
4381
|
tone,
|
|
4380
4382
|
size: handleSizeProp(props.Size.value)
|
|
4381
4383
|
};
|
|
4382
|
-
return createLocalSnippetElement$
|
|
4384
|
+
return createLocalSnippetElement$c("Radiomark", commonProps);
|
|
4383
4385
|
});
|
|
4384
4386
|
|
|
4385
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4387
|
+
const { createLocalSnippetElement: createLocalSnippetElement$b } = createLocalSnippetHelper("reaction-button");
|
|
4386
4388
|
const createReactionButtonHandler = (ctx)=>defineComponentHandler(reactionButton.key, ({ componentProperties: props })=>{
|
|
4387
4389
|
const commonProps = {
|
|
4388
4390
|
size: handleSizeProp(props.Size.value),
|
|
@@ -4396,7 +4398,7 @@ const createReactionButtonHandler = (ctx)=>defineComponentHandler(reactionButton
|
|
|
4396
4398
|
defaultPressed: true
|
|
4397
4399
|
}
|
|
4398
4400
|
};
|
|
4399
|
-
return createLocalSnippetElement$
|
|
4401
|
+
return createLocalSnippetElement$b("ReactionButton", commonProps, [
|
|
4400
4402
|
createSeedReactElement("PrefixIcon", {
|
|
4401
4403
|
svg: ctx.iconHandler.transform(props["Icon#12379:0"])
|
|
4402
4404
|
}),
|
|
@@ -4405,7 +4407,7 @@ const createReactionButtonHandler = (ctx)=>defineComponentHandler(reactionButton
|
|
|
4405
4407
|
]);
|
|
4406
4408
|
});
|
|
4407
4409
|
|
|
4408
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4410
|
+
const { createLocalSnippetElement: createLocalSnippetElement$a } = createLocalSnippetHelper("result-section");
|
|
4409
4411
|
const createResultSectionHandler = (ctx)=>{
|
|
4410
4412
|
const actionButtonHandler = createActionButtonHandler(ctx);
|
|
4411
4413
|
const ghostButtonHandler = createActionButtonGhostHandler(ctx);
|
|
@@ -4443,11 +4445,11 @@ const createResultSectionHandler = (ctx)=>{
|
|
|
4443
4445
|
}
|
|
4444
4446
|
}
|
|
4445
4447
|
};
|
|
4446
|
-
return createLocalSnippetElement$
|
|
4448
|
+
return createLocalSnippetElement$a("ResultSection", commonProps);
|
|
4447
4449
|
});
|
|
4448
4450
|
};
|
|
4449
4451
|
|
|
4450
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4452
|
+
const { createLocalSnippetElement: createLocalSnippetElement$9 } = createLocalSnippetHelper("segmented-control");
|
|
4451
4453
|
const SEGMENTED_CONTROL_ITEM_KEY = "9a7ba0d4c041ddbce84ee48881788434fd6bccc8";
|
|
4452
4454
|
const createSegmentedControlItemHandler = (_ctx)=>defineComponentHandler(SEGMENTED_CONTROL_ITEM_KEY, ({ componentProperties: props })=>{
|
|
4453
4455
|
const states = props.State.value.split("-");
|
|
@@ -4457,7 +4459,7 @@ const createSegmentedControlItemHandler = (_ctx)=>defineComponentHandler(SEGMENT
|
|
|
4457
4459
|
disabled: true
|
|
4458
4460
|
}
|
|
4459
4461
|
};
|
|
4460
|
-
return createLocalSnippetElement$
|
|
4462
|
+
return createLocalSnippetElement$9("SegmentedControlItem", commonProps, props["Label#11366:15"].value);
|
|
4461
4463
|
});
|
|
4462
4464
|
const createSegmentedControlHandler = (ctx)=>{
|
|
4463
4465
|
const segmentedControlItemHandler = createSegmentedControlItemHandler();
|
|
@@ -4473,7 +4475,7 @@ const createSegmentedControlHandler = (ctx)=>{
|
|
|
4473
4475
|
defaultValue: selectedSegment.componentProperties["Label#11366:15"].value
|
|
4474
4476
|
}
|
|
4475
4477
|
};
|
|
4476
|
-
return createLocalSnippetElement$
|
|
4478
|
+
return createLocalSnippetElement$9("SegmentedControl", commonProps, segmentedControlChildren, {
|
|
4477
4479
|
comment: "aria-label이나 aria-labelledby 중 하나를 제공해야 합니다."
|
|
4478
4480
|
});
|
|
4479
4481
|
});
|
|
@@ -4489,7 +4491,7 @@ const createSkeletonHandler = (ctx)=>defineComponentHandler(skeleton.key, (node)
|
|
|
4489
4491
|
return createSeedReactElement("Skeleton", commonProps);
|
|
4490
4492
|
});
|
|
4491
4493
|
|
|
4492
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4494
|
+
const { createLocalSnippetElement: createLocalSnippetElement$8 } = createLocalSnippetHelper("slider");
|
|
4493
4495
|
const SLIDER_TICK_KEY = "ace432ffb7a2af13bce549b19c932ac5f96a9a78";
|
|
4494
4496
|
function getSliderComment(props) {
|
|
4495
4497
|
return [
|
|
@@ -4525,7 +4527,7 @@ const createSliderFieldHandler = (ctx)=>{
|
|
|
4525
4527
|
...headerProps,
|
|
4526
4528
|
...footerProps
|
|
4527
4529
|
};
|
|
4528
|
-
return createLocalSnippetElement$
|
|
4530
|
+
return createLocalSnippetElement$8("Slider", commonProps, undefined, {
|
|
4529
4531
|
comment: getSliderComment(commonProps)
|
|
4530
4532
|
});
|
|
4531
4533
|
});
|
|
@@ -4567,13 +4569,13 @@ const createSliderHandler = (_ctx)=>{
|
|
|
4567
4569
|
disabled: true
|
|
4568
4570
|
}
|
|
4569
4571
|
};
|
|
4570
|
-
return createLocalSnippetElement$
|
|
4572
|
+
return createLocalSnippetElement$8("Slider", commonProps, undefined, {
|
|
4571
4573
|
comment: getSliderComment(commonProps)
|
|
4572
4574
|
});
|
|
4573
4575
|
});
|
|
4574
4576
|
};
|
|
4575
4577
|
|
|
4576
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4578
|
+
const { createLocalSnippetElement: createLocalSnippetElement$7 } = createLocalSnippetHelper("snackbar");
|
|
4577
4579
|
const createSnackbarHandler = (_ctx)=>defineComponentHandler(snackbar.key, ({ componentProperties: props })=>{
|
|
4578
4580
|
const commonProps = {
|
|
4579
4581
|
message: props["Message#1528:4"].value,
|
|
@@ -4583,20 +4585,20 @@ const createSnackbarHandler = (_ctx)=>defineComponentHandler(snackbar.key, ({ co
|
|
|
4583
4585
|
}
|
|
4584
4586
|
};
|
|
4585
4587
|
// TODO: adapter.create({ render })
|
|
4586
|
-
return createLocalSnippetElement$
|
|
4588
|
+
return createLocalSnippetElement$7("Snackbar", commonProps);
|
|
4587
4589
|
});
|
|
4588
4590
|
|
|
4589
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4591
|
+
const { createLocalSnippetElement: createLocalSnippetElement$6 } = createLocalSnippetHelper("switch");
|
|
4590
4592
|
const createSwitchmarkHandler = (_ctx)=>defineComponentHandler(switchmark.key, ({ componentProperties: props })=>{
|
|
4591
4593
|
const tone = match(props.Tone.value).with("Neutral", ()=>"neutral").with("🚫[Deprecated] Brand", ()=>"brand").exhaustive();
|
|
4592
4594
|
const commonProps = {
|
|
4593
4595
|
tone,
|
|
4594
4596
|
size: props.Size.value
|
|
4595
4597
|
};
|
|
4596
|
-
return createLocalSnippetElement$
|
|
4598
|
+
return createLocalSnippetElement$6("Switchmark", commonProps);
|
|
4597
4599
|
});
|
|
4598
4600
|
|
|
4599
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4601
|
+
const { createLocalSnippetElement: createLocalSnippetElement$5 } = createLocalSnippetHelper("switch");
|
|
4600
4602
|
const createSwitchHandler = (_ctx)=>defineComponentHandler(_switch.key, ({ componentProperties: props })=>{
|
|
4601
4603
|
const tone = match(props.Tone.value).with("Neutral", ()=>"neutral").with("🚫[Deprecated] Brand", ()=>"brand").exhaustive();
|
|
4602
4604
|
const commonProps = {
|
|
@@ -4604,9 +4606,9 @@ const createSwitchHandler = (_ctx)=>defineComponentHandler(_switch.key, ({ compo
|
|
|
4604
4606
|
size: props.Size.value
|
|
4605
4607
|
};
|
|
4606
4608
|
if (props["Layout(Figma Only)"].value === "🚫[Switch Mark 사용] Switch Only") {
|
|
4607
|
-
return createLocalSnippetElement$
|
|
4609
|
+
return createLocalSnippetElement$5("Switchmark", commonProps);
|
|
4608
4610
|
}
|
|
4609
|
-
return createLocalSnippetElement$
|
|
4611
|
+
return createLocalSnippetElement$5("Switch", {
|
|
4610
4612
|
...commonProps,
|
|
4611
4613
|
label: props["Label#36578:0"].value,
|
|
4612
4614
|
...props.Selected.value === "True" && {
|
|
@@ -4827,7 +4829,7 @@ const createChipTabsTriggerHandler = (_ctx)=>defineComponentHandler(CHIP_TRIGGER
|
|
|
4827
4829
|
return createChipTabsLocalSnippetElement("ChipTabsTrigger", commonProps);
|
|
4828
4830
|
});
|
|
4829
4831
|
|
|
4830
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
4832
|
+
const { createLocalSnippetElement: createLocalSnippetElement$4 } = createLocalSnippetHelper("text-field");
|
|
4831
4833
|
const TEXT_INPUT_OUTLINE_KEY = "22eebd645d310c086d9f5f69d8f179ff5c7cf7ca";
|
|
4832
4834
|
const TEXT_INPUT_OUTLINE_PREFIX_KEY = "1ab174dd51bc42a5efe530f52f1dd02255c50b18";
|
|
4833
4835
|
const TEXT_INPUT_OUTLINE_SUFFIX_KEY = "555fee288d9053760e301791665bbac31d19c43f";
|
|
@@ -4939,13 +4941,13 @@ const createTextInputFieldHandler = (ctx)=>{
|
|
|
4939
4941
|
placeholder: placeholder.characters
|
|
4940
4942
|
}
|
|
4941
4943
|
};
|
|
4942
|
-
return createLocalSnippetElement$
|
|
4944
|
+
return createLocalSnippetElement$4("TextField", {
|
|
4943
4945
|
...fieldProps,
|
|
4944
4946
|
...commonProps,
|
|
4945
4947
|
...value && {
|
|
4946
4948
|
defaultValue: value.characters
|
|
4947
4949
|
}
|
|
4948
|
-
}, createLocalSnippetElement$
|
|
4950
|
+
}, createLocalSnippetElement$4("TextFieldInput", inputProps));
|
|
4949
4951
|
});
|
|
4950
4952
|
};
|
|
4951
4953
|
const createTextareaFieldHandler = (ctx)=>{
|
|
@@ -4988,14 +4990,14 @@ const createTextareaFieldHandler = (ctx)=>{
|
|
|
4988
4990
|
defaultValue: value.characters
|
|
4989
4991
|
}
|
|
4990
4992
|
};
|
|
4991
|
-
return createLocalSnippetElement$
|
|
4993
|
+
return createLocalSnippetElement$4("TextField", {
|
|
4992
4994
|
...fieldProps,
|
|
4993
4995
|
...commonProps
|
|
4994
|
-
}, createLocalSnippetElement$
|
|
4996
|
+
}, createLocalSnippetElement$4("TextFieldTextarea", inputProps));
|
|
4995
4997
|
});
|
|
4996
4998
|
};
|
|
4997
4999
|
|
|
4998
|
-
const { createLocalSnippetElement: createLocalSnippetElement$
|
|
5000
|
+
const { createLocalSnippetElement: createLocalSnippetElement$3 } = createLocalSnippetHelper("toggle-button");
|
|
4999
5001
|
const createToggleButtonHandler = (ctx)=>defineComponentHandler(toggleButton.key, ({ componentProperties: props })=>{
|
|
5000
5002
|
const commonProps = {
|
|
5001
5003
|
variant: camelCase(props.Variant.value),
|
|
@@ -5010,7 +5012,7 @@ const createToggleButtonHandler = (ctx)=>defineComponentHandler(toggleButton.key
|
|
|
5010
5012
|
loading: true
|
|
5011
5013
|
}
|
|
5012
5014
|
};
|
|
5013
|
-
return createLocalSnippetElement$
|
|
5015
|
+
return createLocalSnippetElement$3("ToggleButton", commonProps, [
|
|
5014
5016
|
props["Show Prefix Icon#6122:392"].value ? createSeedReactElement("PrefixIcon", {
|
|
5015
5017
|
svg: ctx.iconHandler.transform(props["Prefix Icon#6122:98"])
|
|
5016
5018
|
}) : undefined,
|
|
@@ -5021,6 +5023,7 @@ const createToggleButtonHandler = (ctx)=>defineComponentHandler(toggleButton.key
|
|
|
5021
5023
|
]);
|
|
5022
5024
|
});
|
|
5023
5025
|
|
|
5026
|
+
const { createLocalSnippetElement: createLocalSnippetElement$2 } = createLocalSnippetHelper("tag-group");
|
|
5024
5027
|
const createTagGroupHandler = (ctx)=>{
|
|
5025
5028
|
const itemHandler = createTagGroupItemHandler(ctx);
|
|
5026
5029
|
return defineComponentHandler(tagGroup.key, (node, traverse)=>{
|
|
@@ -5030,15 +5033,15 @@ const createTagGroupHandler = (ctx)=>{
|
|
|
5030
5033
|
});
|
|
5031
5034
|
const items = itemNodes.map((itemNode)=>itemHandler.transform(itemNode, traverse));
|
|
5032
5035
|
if (items.length === 0) {
|
|
5033
|
-
return
|
|
5036
|
+
return createLocalSnippetElement$2("TagGroupRoot");
|
|
5034
5037
|
}
|
|
5035
|
-
// if size/weight/tone are all the same among item[n].props, lift them up to
|
|
5038
|
+
// if size/weight/tone are all the same among item[n].props, lift them up to TagGroupRoot
|
|
5036
5039
|
const consistent = {
|
|
5037
5040
|
size: items.map((item)=>item.props.size).every((size)=>size === items[0].props.size),
|
|
5038
5041
|
weight: items.map((item)=>item.props.weight).every((weight)=>weight === items[0].props.weight),
|
|
5039
5042
|
tone: items.map((item)=>item.props.tone).every((tone)=>tone === items[0].props.tone)
|
|
5040
5043
|
};
|
|
5041
|
-
return
|
|
5044
|
+
return createLocalSnippetElement$2("TagGroupRoot", {
|
|
5042
5045
|
// lift up consistent props
|
|
5043
5046
|
...consistent.size && {
|
|
5044
5047
|
size: items[0].props.size
|
|
@@ -5058,27 +5061,26 @@ const createTagGroupHandler = (ctx)=>{
|
|
|
5058
5061
|
weight: consistent.weight ? undefined : item.props.weight,
|
|
5059
5062
|
tone: consistent.tone ? undefined : item.props.tone
|
|
5060
5063
|
}
|
|
5061
|
-
}))
|
|
5064
|
+
})), {
|
|
5065
|
+
comment: "`truncate` prop을 통해 한 줄로 표시되도록 할 수 있습니다."
|
|
5066
|
+
});
|
|
5062
5067
|
});
|
|
5063
5068
|
};
|
|
5064
5069
|
const TAG_GROUP_ITEM_KEY = "a7bbc318919053f96be00e509469f6294d6bb6bb";
|
|
5065
5070
|
const createTagGroupItemHandler = (ctx)=>defineComponentHandler(TAG_GROUP_ITEM_KEY, ({ componentProperties: props })=>{
|
|
5066
5071
|
const size = match(props.Size.value).with("t2(12pt)", ()=>"t2").with("t3(13pt)", ()=>"t3").with("t4(14pt)", ()=>"t4").exhaustive();
|
|
5067
|
-
|
|
5072
|
+
return createLocalSnippetElement$2("TagGroupItem", {
|
|
5068
5073
|
size,
|
|
5069
5074
|
weight: camelCase(props["Weight"].value),
|
|
5070
|
-
tone: camelCase(props["Tone"].value)
|
|
5071
|
-
|
|
5072
|
-
|
|
5073
|
-
|
|
5074
|
-
|
|
5075
|
-
|
|
5076
|
-
|
|
5077
|
-
|
|
5078
|
-
|
|
5079
|
-
}) : undefined
|
|
5080
|
-
].filter(Boolean);
|
|
5081
|
-
return createSeedReactElement("TagGroup.Item", commonProps, children);
|
|
5075
|
+
tone: camelCase(props["Tone"].value),
|
|
5076
|
+
label: props["Label#5409:0"].value,
|
|
5077
|
+
...props.Layout.value === "Icon First" && {
|
|
5078
|
+
prefixIcon: ctx.iconHandler.transform(props["Prefix Icon#47948:0"])
|
|
5079
|
+
},
|
|
5080
|
+
...props.Layout.value === "Icon Last" && {
|
|
5081
|
+
suffixIcon: ctx.iconHandler.transform(props["Suffix Icon#47948:55"])
|
|
5082
|
+
}
|
|
5083
|
+
});
|
|
5082
5084
|
});
|
|
5083
5085
|
|
|
5084
5086
|
const { createLocalSnippetElement: createLocalSnippetElement$1 } = createLocalSnippetHelper("text-field");
|