@feelflow/ffid-sdk 2.9.0 → 2.11.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/dist/{chunk-5SD6KOYJ.js → chunk-2OAFWUEL.js} +229 -180
- package/dist/{chunk-2LD6Y65W.cjs → chunk-BEHDXUB2.cjs} +229 -180
- package/dist/components/index.cjs +8 -8
- package/dist/components/index.d.cts +1 -1
- package/dist/components/index.d.ts +1 -1
- package/dist/components/index.js +1 -1
- package/dist/{index-R2ALICqm.d.cts → index-BuT9VaRt.d.cts} +137 -29
- package/dist/{index-R2ALICqm.d.ts → index-BuT9VaRt.d.ts} +137 -29
- package/dist/index.cjs +24 -24
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +2 -2
- package/dist/server/index.cjs +1 -1
- package/dist/server/index.js +1 -1
- package/package.json +1 -1
|
@@ -619,7 +619,7 @@ function createMembersMethods(deps) {
|
|
|
619
619
|
}
|
|
620
620
|
|
|
621
621
|
// src/client/version-check.ts
|
|
622
|
-
var SDK_VERSION = "2.
|
|
622
|
+
var SDK_VERSION = "2.11.0";
|
|
623
623
|
var SDK_USER_AGENT = `FFID-SDK/${SDK_VERSION} (TypeScript)`;
|
|
624
624
|
var SDK_VERSION_HEADER = "X-FFID-SDK-Version";
|
|
625
625
|
function sdkHeaders() {
|
|
@@ -3420,43 +3420,9 @@ var FFID_INQUIRY_CATEGORIES = [
|
|
|
3420
3420
|
"press",
|
|
3421
3421
|
"other"
|
|
3422
3422
|
];
|
|
3423
|
-
var
|
|
3424
|
-
|
|
3425
|
-
|
|
3426
|
-
support: "\u30B5\u30DD\u30FC\u30C8",
|
|
3427
|
-
partnership: "\u30D1\u30FC\u30C8\u30CA\u30FC\u30B7\u30C3\u30D7",
|
|
3428
|
-
press: "\u53D6\u6750\u30FB\u30D7\u30EC\u30B9",
|
|
3429
|
-
other: "\u305D\u306E\u4ED6"
|
|
3430
|
-
};
|
|
3431
|
-
function defaultCategories() {
|
|
3432
|
-
return FFID_INQUIRY_CATEGORIES.map((value) => ({
|
|
3433
|
-
value,
|
|
3434
|
-
label: DEFAULT_CATEGORY_LABELS_JA[value]
|
|
3435
|
-
}));
|
|
3436
|
-
}
|
|
3437
|
-
function renderCategoryOptions(options) {
|
|
3438
|
-
const hasAnyGroup = options.some((o) => !!o.group);
|
|
3439
|
-
if (!hasAnyGroup) {
|
|
3440
|
-
return options.map((opt) => /* @__PURE__ */ jsx("option", { value: opt.value, children: opt.label }, opt.value));
|
|
3441
|
-
}
|
|
3442
|
-
const ungrouped = options.filter((o) => !o.group);
|
|
3443
|
-
const groupKeys = [];
|
|
3444
|
-
const groupLabelByKey = /* @__PURE__ */ new Map();
|
|
3445
|
-
const itemsByKey = /* @__PURE__ */ new Map();
|
|
3446
|
-
for (const opt of options) {
|
|
3447
|
-
if (!opt.group) continue;
|
|
3448
|
-
if (!itemsByKey.has(opt.group)) {
|
|
3449
|
-
groupKeys.push(opt.group);
|
|
3450
|
-
itemsByKey.set(opt.group, []);
|
|
3451
|
-
groupLabelByKey.set(opt.group, opt.groupLabel ?? opt.group);
|
|
3452
|
-
}
|
|
3453
|
-
itemsByKey.get(opt.group).push(opt);
|
|
3454
|
-
}
|
|
3455
|
-
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
3456
|
-
ungrouped.map((opt) => /* @__PURE__ */ jsx("option", { value: opt.value, children: opt.label }, opt.value)),
|
|
3457
|
-
groupKeys.map((key) => /* @__PURE__ */ jsx("optgroup", { label: groupLabelByKey.get(key) ?? key, children: itemsByKey.get(key).map((opt) => /* @__PURE__ */ jsx("option", { value: opt.value, children: opt.label }, opt.value)) }, key))
|
|
3458
|
-
] });
|
|
3459
|
-
}
|
|
3423
|
+
var CATEGORY_PLACEHOLDER_LABEL_JA = "\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044";
|
|
3424
|
+
var CATEGORY_REQUIRED_ERROR_JA = "\u304A\u554F\u3044\u5408\u308F\u305B\u7A2E\u5225\u3092\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044\u3002";
|
|
3425
|
+
var SUBMIT_BUTTON_OPACITY_PENDING = 0.6;
|
|
3460
3426
|
var labelStyle = {
|
|
3461
3427
|
display: "block",
|
|
3462
3428
|
fontSize: FONT_SIZE_SM,
|
|
@@ -3496,7 +3462,58 @@ var submitButtonStyle = {
|
|
|
3496
3462
|
borderRadius: BORDER_RADIUS_MD,
|
|
3497
3463
|
cursor: "pointer"
|
|
3498
3464
|
};
|
|
3499
|
-
var
|
|
3465
|
+
var successBlockStyle = {
|
|
3466
|
+
padding: SPACING_LG,
|
|
3467
|
+
border: BORDER_DEFAULT,
|
|
3468
|
+
borderRadius: BORDER_RADIUS_MD,
|
|
3469
|
+
background: "#f0fdf4",
|
|
3470
|
+
color: "#166534",
|
|
3471
|
+
fontSize: FONT_SIZE_SM
|
|
3472
|
+
};
|
|
3473
|
+
function cx(...parts) {
|
|
3474
|
+
const joined = parts.filter((p) => !!p).join(" ");
|
|
3475
|
+
return joined.length > 0 ? joined : void 0;
|
|
3476
|
+
}
|
|
3477
|
+
function styleOrUndefined(style, unstyled) {
|
|
3478
|
+
return unstyled ? void 0 : style;
|
|
3479
|
+
}
|
|
3480
|
+
var DEFAULT_CATEGORY_LABELS_JA = {
|
|
3481
|
+
general: "\u4E00\u822C\u7684\u306A\u304A\u554F\u3044\u5408\u308F\u305B",
|
|
3482
|
+
sales: "\u3054\u5C0E\u5165\u30FB\u304A\u898B\u7A4D\u3082\u308A",
|
|
3483
|
+
support: "\u30B5\u30DD\u30FC\u30C8",
|
|
3484
|
+
partnership: "\u30D1\u30FC\u30C8\u30CA\u30FC\u30B7\u30C3\u30D7",
|
|
3485
|
+
press: "\u53D6\u6750\u30FB\u30D7\u30EC\u30B9",
|
|
3486
|
+
other: "\u305D\u306E\u4ED6"
|
|
3487
|
+
};
|
|
3488
|
+
function defaultCategories() {
|
|
3489
|
+
return FFID_INQUIRY_CATEGORIES.map((value) => ({
|
|
3490
|
+
value,
|
|
3491
|
+
label: DEFAULT_CATEGORY_LABELS_JA[value]
|
|
3492
|
+
}));
|
|
3493
|
+
}
|
|
3494
|
+
function renderCategoryOptions(options) {
|
|
3495
|
+
const hasAnyGroup = options.some((o) => !!o.group);
|
|
3496
|
+
if (!hasAnyGroup) {
|
|
3497
|
+
return options.map((opt) => /* @__PURE__ */ jsx("option", { value: opt.value, children: opt.label }, opt.value));
|
|
3498
|
+
}
|
|
3499
|
+
const ungrouped = options.filter((o) => !o.group);
|
|
3500
|
+
const groupKeys = [];
|
|
3501
|
+
const groupLabelByKey = /* @__PURE__ */ new Map();
|
|
3502
|
+
const itemsByKey = /* @__PURE__ */ new Map();
|
|
3503
|
+
for (const opt of options) {
|
|
3504
|
+
if (!opt.group) continue;
|
|
3505
|
+
if (!itemsByKey.has(opt.group)) {
|
|
3506
|
+
groupKeys.push(opt.group);
|
|
3507
|
+
itemsByKey.set(opt.group, []);
|
|
3508
|
+
groupLabelByKey.set(opt.group, opt.groupLabel ?? opt.group);
|
|
3509
|
+
}
|
|
3510
|
+
itemsByKey.get(opt.group).push(opt);
|
|
3511
|
+
}
|
|
3512
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
3513
|
+
ungrouped.map((opt) => /* @__PURE__ */ jsx("option", { value: opt.value, children: opt.label }, opt.value)),
|
|
3514
|
+
groupKeys.map((key) => /* @__PURE__ */ jsx("optgroup", { label: groupLabelByKey.get(key) ?? key, children: itemsByKey.get(key).map((opt) => /* @__PURE__ */ jsx("option", { value: opt.value, children: opt.label }, opt.value)) }, key))
|
|
3515
|
+
] });
|
|
3516
|
+
}
|
|
3500
3517
|
function FFIDInquiryForm({
|
|
3501
3518
|
mode,
|
|
3502
3519
|
prefill,
|
|
@@ -3512,6 +3529,10 @@ function FFIDInquiryForm({
|
|
|
3512
3529
|
onSubmit,
|
|
3513
3530
|
onChange,
|
|
3514
3531
|
separateLegalCheckboxes = false,
|
|
3532
|
+
messagePlaceholder,
|
|
3533
|
+
requireCategorySelection = false,
|
|
3534
|
+
unstyled = false,
|
|
3535
|
+
classNames,
|
|
3515
3536
|
locale = "ja",
|
|
3516
3537
|
className
|
|
3517
3538
|
}) {
|
|
@@ -3529,11 +3550,20 @@ function FFIDInquiryForm({
|
|
|
3529
3550
|
return null;
|
|
3530
3551
|
}, [isAuth, organizations, preselectedOrganizationId]);
|
|
3531
3552
|
const initialCategory = useMemo(() => {
|
|
3532
|
-
const fallback = categoryOptions[0]?.value ?? "general";
|
|
3533
3553
|
const requested = prefill?.category;
|
|
3534
|
-
if (
|
|
3535
|
-
|
|
3536
|
-
|
|
3554
|
+
if (requested && categoryOptions.some((opt) => opt.value === requested)) {
|
|
3555
|
+
return requested;
|
|
3556
|
+
}
|
|
3557
|
+
if (requireCategorySelection) return "";
|
|
3558
|
+
const first = categoryOptions[0]?.value;
|
|
3559
|
+
if (first === void 0) {
|
|
3560
|
+
console.error(
|
|
3561
|
+
"[FFIDInquiryForm] categoryOptions is empty; set requireCategorySelection=true or provide at least one category. Submits will be blocked until a value is picked."
|
|
3562
|
+
);
|
|
3563
|
+
return "";
|
|
3564
|
+
}
|
|
3565
|
+
return first;
|
|
3566
|
+
}, [categoryOptions, prefill?.category, requireCategorySelection]);
|
|
3537
3567
|
const [name, setName] = useState(prefill?.name ?? "");
|
|
3538
3568
|
const [email, setEmail] = useState(prefill?.email ?? "");
|
|
3539
3569
|
const [company, setCompany] = useState(isAuth ? "" : prefill?.company ?? "");
|
|
@@ -3549,6 +3579,11 @@ function FFIDInquiryForm({
|
|
|
3549
3579
|
const [submitting, setSubmitting] = useState(false);
|
|
3550
3580
|
const [formError, setFormError] = useState(null);
|
|
3551
3581
|
const [successMessage, setSuccessMessage] = useState(null);
|
|
3582
|
+
const resolvedMessagePlaceholder = useMemo(() => {
|
|
3583
|
+
if (messagePlaceholder === void 0) return void 0;
|
|
3584
|
+
if (typeof messagePlaceholder === "string") return messagePlaceholder;
|
|
3585
|
+
return messagePlaceholder({ category: category === "" ? null : category });
|
|
3586
|
+
}, [messagePlaceholder, category]);
|
|
3552
3587
|
const [hydrated, setHydrated] = useState(false);
|
|
3553
3588
|
useEffect(() => {
|
|
3554
3589
|
setHydrated(true);
|
|
@@ -3558,6 +3593,7 @@ function FFIDInquiryForm({
|
|
|
3558
3593
|
onChangeRef.current = onChange;
|
|
3559
3594
|
}, [onChange]);
|
|
3560
3595
|
useEffect(() => {
|
|
3596
|
+
if (category === "") return;
|
|
3561
3597
|
onChangeRef.current?.({
|
|
3562
3598
|
name: name.trim(),
|
|
3563
3599
|
email: email.trim(),
|
|
@@ -3588,6 +3624,7 @@ function FFIDInquiryForm({
|
|
|
3588
3624
|
turnstileToken,
|
|
3589
3625
|
locale
|
|
3590
3626
|
]);
|
|
3627
|
+
const s = (style) => styleOrUndefined(style, unstyled);
|
|
3591
3628
|
async function handleSubmit(e) {
|
|
3592
3629
|
e.preventDefault();
|
|
3593
3630
|
setFormError(null);
|
|
@@ -3608,15 +3645,17 @@ function FFIDInquiryForm({
|
|
|
3608
3645
|
setFormError("\u5229\u7528\u898F\u7D04\u3068\u30D7\u30E9\u30A4\u30D0\u30B7\u30FC\u30DD\u30EA\u30B7\u30FC\u3078\u306E\u540C\u610F\u304C\u5FC5\u8981\u3067\u3059\u3002");
|
|
3609
3646
|
return;
|
|
3610
3647
|
}
|
|
3648
|
+
if (requireCategorySelection && !category) {
|
|
3649
|
+
setFormError(CATEGORY_REQUIRED_ERROR_JA);
|
|
3650
|
+
return;
|
|
3651
|
+
}
|
|
3611
3652
|
if (!message.trim()) {
|
|
3612
3653
|
setFormError("\u304A\u554F\u3044\u5408\u308F\u305B\u5185\u5BB9\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044\u3002");
|
|
3613
3654
|
return;
|
|
3614
3655
|
}
|
|
3615
|
-
if (!isAuth) {
|
|
3616
|
-
|
|
3617
|
-
|
|
3618
|
-
return;
|
|
3619
|
-
}
|
|
3656
|
+
if (!isAuth && (!name.trim() || !email.trim())) {
|
|
3657
|
+
setFormError("\u304A\u540D\u524D\u3068\u30E1\u30FC\u30EB\u30A2\u30C9\u30EC\u30B9\u3092\u5165\u529B\u3057\u3066\u304F\u3060\u3055\u3044\u3002");
|
|
3658
|
+
return;
|
|
3620
3659
|
}
|
|
3621
3660
|
setSubmitting(true);
|
|
3622
3661
|
try {
|
|
@@ -3641,9 +3680,7 @@ function FFIDInquiryForm({
|
|
|
3641
3680
|
);
|
|
3642
3681
|
setMessage("");
|
|
3643
3682
|
} else {
|
|
3644
|
-
setFormError(
|
|
3645
|
-
result.message ?? "\u9001\u4FE1\u306B\u5931\u6557\u3057\u307E\u3057\u305F\u3002\u6642\u9593\u3092\u304A\u3044\u3066\u518D\u5EA6\u304A\u8A66\u3057\u304F\u3060\u3055\u3044\u3002"
|
|
3646
|
-
);
|
|
3683
|
+
setFormError(result.message ?? "\u9001\u4FE1\u306B\u5931\u6557\u3057\u307E\u3057\u305F\u3002\u6642\u9593\u3092\u304A\u3044\u3066\u518D\u5EA6\u304A\u8A66\u3057\u304F\u3060\u3055\u3044\u3002");
|
|
3647
3684
|
}
|
|
3648
3685
|
} catch (err) {
|
|
3649
3686
|
console.error("[FFIDInquiryForm] onSubmit threw", err);
|
|
@@ -3657,35 +3694,56 @@ function FFIDInquiryForm({
|
|
|
3657
3694
|
"div",
|
|
3658
3695
|
{
|
|
3659
3696
|
role: "status",
|
|
3660
|
-
className,
|
|
3661
|
-
style:
|
|
3662
|
-
padding: SPACING_LG,
|
|
3663
|
-
border: BORDER_DEFAULT,
|
|
3664
|
-
borderRadius: BORDER_RADIUS_MD,
|
|
3665
|
-
background: "#f0fdf4",
|
|
3666
|
-
color: "#166534",
|
|
3667
|
-
fontSize: FONT_SIZE_SM
|
|
3668
|
-
},
|
|
3697
|
+
className: cx(className, classNames?.form, classNames?.successBlock),
|
|
3698
|
+
style: s(successBlockStyle),
|
|
3669
3699
|
children: successMessage
|
|
3670
3700
|
}
|
|
3671
3701
|
);
|
|
3672
3702
|
}
|
|
3673
3703
|
const showOrgBlock = isAuth && organizations.length >= 1;
|
|
3704
|
+
const rowStyle = { display: "flex", alignItems: "center", gap: SPACING_SM, marginBottom: SPACING_SM };
|
|
3705
|
+
const rowStyleLast = { display: "flex", alignItems: "center", gap: SPACING_SM };
|
|
3706
|
+
const legalRowFirst = { display: "flex", alignItems: "flex-start", gap: SPACING_SM, marginBottom: SPACING_SM };
|
|
3707
|
+
const legalRowLast = { display: "flex", alignItems: "flex-start", gap: SPACING_SM };
|
|
3708
|
+
const spanStyle = { fontSize: FONT_SIZE_SM };
|
|
3709
|
+
function renderTermsLink() {
|
|
3710
|
+
return termsHref ? /* @__PURE__ */ jsxs("a", { href: termsHref, target: "_blank", rel: "noopener noreferrer", className: classNames?.legalLink, children: [
|
|
3711
|
+
"\u5229\u7528\u898F\u7D04 (v",
|
|
3712
|
+
termsVersion,
|
|
3713
|
+
")"
|
|
3714
|
+
] }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
3715
|
+
"\u5229\u7528\u898F\u7D04 (v",
|
|
3716
|
+
termsVersion,
|
|
3717
|
+
")"
|
|
3718
|
+
] });
|
|
3719
|
+
}
|
|
3720
|
+
function renderPrivacyLink() {
|
|
3721
|
+
return privacyHref ? /* @__PURE__ */ jsxs("a", { href: privacyHref, target: "_blank", rel: "noopener noreferrer", className: classNames?.legalLink, children: [
|
|
3722
|
+
"\u30D7\u30E9\u30A4\u30D0\u30B7\u30FC\u30DD\u30EA\u30B7\u30FC (v",
|
|
3723
|
+
privacyVersion,
|
|
3724
|
+
")"
|
|
3725
|
+
] }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
3726
|
+
"\u30D7\u30E9\u30A4\u30D0\u30B7\u30FC\u30DD\u30EA\u30B7\u30FC (v",
|
|
3727
|
+
privacyVersion,
|
|
3728
|
+
")"
|
|
3729
|
+
] });
|
|
3730
|
+
}
|
|
3674
3731
|
return /* @__PURE__ */ jsxs(
|
|
3675
3732
|
"form",
|
|
3676
3733
|
{
|
|
3677
3734
|
onSubmit: handleSubmit,
|
|
3678
|
-
className,
|
|
3735
|
+
className: cx(className, classNames?.form),
|
|
3679
3736
|
noValidate: true,
|
|
3680
3737
|
"data-hydrated": hydrated ? "true" : void 0,
|
|
3681
3738
|
children: [
|
|
3682
|
-
showOrgBlock && /* @__PURE__ */ jsxs("div", { style: fieldsetStyle, children: [
|
|
3683
|
-
/* @__PURE__ */ jsx("label", { style: labelStyle, htmlFor: "ffid-inquiry-org", children: "\u554F\u3044\u5408\u308F\u305B\u308B\u7ACB\u5834" }),
|
|
3739
|
+
showOrgBlock && /* @__PURE__ */ jsxs("div", { style: s(fieldsetStyle), className: cx(classNames?.field, classNames?.orgSelectWrapper), children: [
|
|
3740
|
+
/* @__PURE__ */ jsx("label", { style: s(labelStyle), className: classNames?.label, htmlFor: "ffid-inquiry-org", children: "\u554F\u3044\u5408\u308F\u305B\u308B\u7ACB\u5834" }),
|
|
3684
3741
|
/* @__PURE__ */ jsxs(
|
|
3685
3742
|
"select",
|
|
3686
3743
|
{
|
|
3687
3744
|
id: "ffid-inquiry-org",
|
|
3688
|
-
style: inputStyle,
|
|
3745
|
+
style: s(inputStyle),
|
|
3746
|
+
className: classNames?.select,
|
|
3689
3747
|
value: organizationId ?? "",
|
|
3690
3748
|
onChange: (e) => setOrganizationId(e.target.value || null),
|
|
3691
3749
|
children: [
|
|
@@ -3698,13 +3756,14 @@ function FFIDInquiryForm({
|
|
|
3698
3756
|
}
|
|
3699
3757
|
)
|
|
3700
3758
|
] }),
|
|
3701
|
-
/* @__PURE__ */ jsxs("div", { style: fieldsetStyle, children: [
|
|
3702
|
-
/* @__PURE__ */ jsx("label", { style: labelStyle, htmlFor: "ffid-inquiry-name", children: "\u304A\u540D\u524D" }),
|
|
3759
|
+
/* @__PURE__ */ jsxs("div", { style: s(fieldsetStyle), className: classNames?.field, children: [
|
|
3760
|
+
/* @__PURE__ */ jsx("label", { style: s(labelStyle), className: classNames?.label, htmlFor: "ffid-inquiry-name", children: "\u304A\u540D\u524D" }),
|
|
3703
3761
|
/* @__PURE__ */ jsx(
|
|
3704
3762
|
"input",
|
|
3705
3763
|
{
|
|
3706
3764
|
id: "ffid-inquiry-name",
|
|
3707
|
-
style: isNameReadOnly ? readOnlyStyle : inputStyle,
|
|
3765
|
+
style: s(isNameReadOnly ? readOnlyStyle : inputStyle),
|
|
3766
|
+
className: cx(classNames?.input, isNameReadOnly ? classNames?.readOnlyInput : void 0),
|
|
3708
3767
|
type: "text",
|
|
3709
3768
|
value: name,
|
|
3710
3769
|
onChange: (e) => setName(e.target.value),
|
|
@@ -3713,13 +3772,14 @@ function FFIDInquiryForm({
|
|
|
3713
3772
|
}
|
|
3714
3773
|
)
|
|
3715
3774
|
] }),
|
|
3716
|
-
/* @__PURE__ */ jsxs("div", { style: fieldsetStyle, children: [
|
|
3717
|
-
/* @__PURE__ */ jsx("label", { style: labelStyle, htmlFor: "ffid-inquiry-email", children: "\u30E1\u30FC\u30EB\u30A2\u30C9\u30EC\u30B9" }),
|
|
3775
|
+
/* @__PURE__ */ jsxs("div", { style: s(fieldsetStyle), className: classNames?.field, children: [
|
|
3776
|
+
/* @__PURE__ */ jsx("label", { style: s(labelStyle), className: classNames?.label, htmlFor: "ffid-inquiry-email", children: "\u30E1\u30FC\u30EB\u30A2\u30C9\u30EC\u30B9" }),
|
|
3718
3777
|
/* @__PURE__ */ jsx(
|
|
3719
3778
|
"input",
|
|
3720
3779
|
{
|
|
3721
3780
|
id: "ffid-inquiry-email",
|
|
3722
|
-
style: isEmailReadOnly ? readOnlyStyle : inputStyle,
|
|
3781
|
+
style: s(isEmailReadOnly ? readOnlyStyle : inputStyle),
|
|
3782
|
+
className: cx(classNames?.input, isEmailReadOnly ? classNames?.readOnlyInput : void 0),
|
|
3723
3783
|
type: "email",
|
|
3724
3784
|
value: email,
|
|
3725
3785
|
onChange: (e) => setEmail(e.target.value),
|
|
@@ -3729,26 +3789,28 @@ function FFIDInquiryForm({
|
|
|
3729
3789
|
)
|
|
3730
3790
|
] }),
|
|
3731
3791
|
!isAuth && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
3732
|
-
/* @__PURE__ */ jsxs("div", { style: fieldsetStyle, children: [
|
|
3733
|
-
/* @__PURE__ */ jsx("label", { style: labelStyle, htmlFor: "ffid-inquiry-company", children: "\u4F1A\u793E\u540D (\u4EFB\u610F)" }),
|
|
3792
|
+
/* @__PURE__ */ jsxs("div", { style: s(fieldsetStyle), className: classNames?.field, children: [
|
|
3793
|
+
/* @__PURE__ */ jsx("label", { style: s(labelStyle), className: classNames?.label, htmlFor: "ffid-inquiry-company", children: "\u4F1A\u793E\u540D (\u4EFB\u610F)" }),
|
|
3734
3794
|
/* @__PURE__ */ jsx(
|
|
3735
3795
|
"input",
|
|
3736
3796
|
{
|
|
3737
3797
|
id: "ffid-inquiry-company",
|
|
3738
|
-
style: inputStyle,
|
|
3798
|
+
style: s(inputStyle),
|
|
3799
|
+
className: classNames?.input,
|
|
3739
3800
|
type: "text",
|
|
3740
3801
|
value: company,
|
|
3741
3802
|
onChange: (e) => setCompany(e.target.value)
|
|
3742
3803
|
}
|
|
3743
3804
|
)
|
|
3744
3805
|
] }),
|
|
3745
|
-
/* @__PURE__ */ jsxs("div", { style: fieldsetStyle, children: [
|
|
3746
|
-
/* @__PURE__ */ jsx("label", { style: labelStyle, htmlFor: "ffid-inquiry-phone", children: "\u96FB\u8A71\u756A\u53F7 (\u4EFB\u610F)" }),
|
|
3806
|
+
/* @__PURE__ */ jsxs("div", { style: s(fieldsetStyle), className: classNames?.field, children: [
|
|
3807
|
+
/* @__PURE__ */ jsx("label", { style: s(labelStyle), className: classNames?.label, htmlFor: "ffid-inquiry-phone", children: "\u96FB\u8A71\u756A\u53F7 (\u4EFB\u610F)" }),
|
|
3747
3808
|
/* @__PURE__ */ jsx(
|
|
3748
3809
|
"input",
|
|
3749
3810
|
{
|
|
3750
3811
|
id: "ffid-inquiry-phone",
|
|
3751
|
-
style: inputStyle,
|
|
3812
|
+
style: s(inputStyle),
|
|
3813
|
+
className: classNames?.input,
|
|
3752
3814
|
type: "tel",
|
|
3753
3815
|
value: phone,
|
|
3754
3816
|
onChange: (e) => setPhone(e.target.value)
|
|
@@ -3756,165 +3818,152 @@ function FFIDInquiryForm({
|
|
|
3756
3818
|
)
|
|
3757
3819
|
] })
|
|
3758
3820
|
] }),
|
|
3759
|
-
/* @__PURE__ */ jsxs("div", { style: fieldsetStyle, children: [
|
|
3760
|
-
/* @__PURE__ */ jsx("label", { style: labelStyle, htmlFor: "ffid-inquiry-category", children: "\u304A\u554F\u3044\u5408\u308F\u305B\u7A2E\u5225" }),
|
|
3761
|
-
/* @__PURE__ */
|
|
3821
|
+
/* @__PURE__ */ jsxs("div", { style: s(fieldsetStyle), className: classNames?.field, children: [
|
|
3822
|
+
/* @__PURE__ */ jsx("label", { style: s(labelStyle), className: classNames?.label, htmlFor: "ffid-inquiry-category", children: "\u304A\u554F\u3044\u5408\u308F\u305B\u7A2E\u5225" }),
|
|
3823
|
+
/* @__PURE__ */ jsxs(
|
|
3762
3824
|
"select",
|
|
3763
3825
|
{
|
|
3764
3826
|
id: "ffid-inquiry-category",
|
|
3765
|
-
style: inputStyle,
|
|
3827
|
+
style: s(inputStyle),
|
|
3828
|
+
className: classNames?.select,
|
|
3766
3829
|
value: category,
|
|
3767
3830
|
onChange: (e) => setCategory(e.target.value),
|
|
3768
|
-
|
|
3831
|
+
required: requireCategorySelection,
|
|
3832
|
+
children: [
|
|
3833
|
+
requireCategorySelection && /* @__PURE__ */ jsx("option", { value: "", disabled: true, className: classNames?.categoryPlaceholderOption, children: CATEGORY_PLACEHOLDER_LABEL_JA }),
|
|
3834
|
+
renderCategoryOptions(categoryOptions)
|
|
3835
|
+
]
|
|
3769
3836
|
}
|
|
3770
3837
|
)
|
|
3771
3838
|
] }),
|
|
3772
|
-
/* @__PURE__ */ jsxs("div", { style: fieldsetStyle, children: [
|
|
3773
|
-
/* @__PURE__ */ jsx("label", { style: labelStyle, htmlFor: "ffid-inquiry-message", children: "\u304A\u554F\u3044\u5408\u308F\u305B\u5185\u5BB9" }),
|
|
3839
|
+
/* @__PURE__ */ jsxs("div", { style: s(fieldsetStyle), className: classNames?.field, children: [
|
|
3840
|
+
/* @__PURE__ */ jsx("label", { style: s(labelStyle), className: classNames?.label, htmlFor: "ffid-inquiry-message", children: "\u304A\u554F\u3044\u5408\u308F\u305B\u5185\u5BB9" }),
|
|
3774
3841
|
/* @__PURE__ */ jsx(
|
|
3775
3842
|
"textarea",
|
|
3776
3843
|
{
|
|
3777
3844
|
id: "ffid-inquiry-message",
|
|
3778
|
-
style: { ...inputStyle, minHeight: 180, resize: "vertical" },
|
|
3845
|
+
style: s({ ...inputStyle, minHeight: 180, resize: "vertical" }),
|
|
3846
|
+
className: classNames?.textarea,
|
|
3779
3847
|
value: message,
|
|
3780
3848
|
onChange: (e) => setMessage(e.target.value),
|
|
3849
|
+
placeholder: resolvedMessagePlaceholder,
|
|
3781
3850
|
required: true,
|
|
3782
3851
|
maxLength: 1e4
|
|
3783
3852
|
}
|
|
3784
3853
|
)
|
|
3785
3854
|
] }),
|
|
3786
|
-
/* @__PURE__ */ jsxs(
|
|
3787
|
-
|
|
3788
|
-
|
|
3855
|
+
/* @__PURE__ */ jsxs(
|
|
3856
|
+
"fieldset",
|
|
3857
|
+
{
|
|
3858
|
+
style: s({ ...fieldsetStyle, border: "none", padding: 0 }),
|
|
3859
|
+
className: classNames?.newsletterFieldset,
|
|
3860
|
+
children: [
|
|
3861
|
+
/* @__PURE__ */ jsx(
|
|
3862
|
+
"legend",
|
|
3863
|
+
{
|
|
3864
|
+
style: s({ ...labelStyle, marginBottom: SPACING_SM }),
|
|
3865
|
+
className: cx(classNames?.label, classNames?.newsletterLegend),
|
|
3866
|
+
children: "\u30CB\u30E5\u30FC\u30B9\u30EC\u30BF\u30FC\u8CFC\u8AAD (\u4EFB\u610F)"
|
|
3867
|
+
}
|
|
3868
|
+
),
|
|
3869
|
+
/* @__PURE__ */ jsxs("label", { style: s(rowStyle), className: classNames?.newsletterRow, children: [
|
|
3870
|
+
/* @__PURE__ */ jsx(
|
|
3871
|
+
"input",
|
|
3872
|
+
{
|
|
3873
|
+
type: "checkbox",
|
|
3874
|
+
className: classNames?.newsletterCheckbox,
|
|
3875
|
+
checked: inquiryFollowup,
|
|
3876
|
+
onChange: (e) => setInquiryFollowup(e.target.checked)
|
|
3877
|
+
}
|
|
3878
|
+
),
|
|
3879
|
+
/* @__PURE__ */ jsx("span", { style: s(spanStyle), children: "\u304A\u554F\u3044\u5408\u308F\u305B\u306B\u95A2\u9023\u3059\u308B\u6848\u5185\u3092\u53D7\u3051\u53D6\u308B" })
|
|
3880
|
+
] }),
|
|
3881
|
+
/* @__PURE__ */ jsxs("label", { style: s(rowStyleLast), className: classNames?.newsletterRow, children: [
|
|
3882
|
+
/* @__PURE__ */ jsx(
|
|
3883
|
+
"input",
|
|
3884
|
+
{
|
|
3885
|
+
type: "checkbox",
|
|
3886
|
+
className: classNames?.newsletterCheckbox,
|
|
3887
|
+
checked: general,
|
|
3888
|
+
onChange: (e) => setGeneral(e.target.checked)
|
|
3889
|
+
}
|
|
3890
|
+
),
|
|
3891
|
+
/* @__PURE__ */ jsx("span", { style: s(spanStyle), children: "\u5B9A\u671F\u30CB\u30E5\u30FC\u30B9\u30EC\u30BF\u30FC\u3092\u53D7\u3051\u53D6\u308B" })
|
|
3892
|
+
] })
|
|
3893
|
+
]
|
|
3894
|
+
}
|
|
3895
|
+
),
|
|
3896
|
+
separateLegalCheckboxes ? /* @__PURE__ */ jsxs("div", { style: s(fieldsetStyle), className: classNames?.legalBlock, children: [
|
|
3897
|
+
/* @__PURE__ */ jsxs("label", { style: s(legalRowFirst), className: classNames?.legalRow, children: [
|
|
3789
3898
|
/* @__PURE__ */ jsx(
|
|
3790
3899
|
"input",
|
|
3791
3900
|
{
|
|
3792
3901
|
type: "checkbox",
|
|
3793
|
-
|
|
3794
|
-
|
|
3902
|
+
className: classNames?.legalCheckbox,
|
|
3903
|
+
checked: agreedTerms,
|
|
3904
|
+
onChange: (e) => setAgreedTerms(e.target.checked),
|
|
3905
|
+
required: true
|
|
3795
3906
|
}
|
|
3796
3907
|
),
|
|
3797
|
-
/* @__PURE__ */
|
|
3908
|
+
/* @__PURE__ */ jsxs("span", { style: s(spanStyle), children: [
|
|
3909
|
+
renderTermsLink(),
|
|
3910
|
+
" \u306B\u540C\u610F\u3057\u307E\u3059\u3002"
|
|
3911
|
+
] })
|
|
3798
3912
|
] }),
|
|
3799
|
-
/* @__PURE__ */ jsxs("label", { style:
|
|
3800
|
-
/* @__PURE__ */ jsx(
|
|
3801
|
-
"input",
|
|
3802
|
-
{
|
|
3803
|
-
type: "checkbox",
|
|
3804
|
-
checked: general,
|
|
3805
|
-
onChange: (e) => setGeneral(e.target.checked)
|
|
3806
|
-
}
|
|
3807
|
-
),
|
|
3808
|
-
/* @__PURE__ */ jsx("span", { style: { fontSize: FONT_SIZE_SM }, children: "\u5B9A\u671F\u30CB\u30E5\u30FC\u30B9\u30EC\u30BF\u30FC\u3092\u53D7\u3051\u53D6\u308B" })
|
|
3809
|
-
] })
|
|
3810
|
-
] }),
|
|
3811
|
-
separateLegalCheckboxes ? /* @__PURE__ */ jsxs("div", { style: fieldsetStyle, children: [
|
|
3812
|
-
/* @__PURE__ */ jsxs(
|
|
3813
|
-
"label",
|
|
3814
|
-
{
|
|
3815
|
-
style: {
|
|
3816
|
-
display: "flex",
|
|
3817
|
-
alignItems: "flex-start",
|
|
3818
|
-
gap: SPACING_SM,
|
|
3819
|
-
marginBottom: SPACING_SM
|
|
3820
|
-
},
|
|
3821
|
-
children: [
|
|
3822
|
-
/* @__PURE__ */ jsx(
|
|
3823
|
-
"input",
|
|
3824
|
-
{
|
|
3825
|
-
type: "checkbox",
|
|
3826
|
-
checked: agreedTerms,
|
|
3827
|
-
onChange: (e) => setAgreedTerms(e.target.checked),
|
|
3828
|
-
required: true
|
|
3829
|
-
}
|
|
3830
|
-
),
|
|
3831
|
-
/* @__PURE__ */ jsxs("span", { style: { fontSize: FONT_SIZE_SM }, children: [
|
|
3832
|
-
termsHref ? /* @__PURE__ */ jsxs("a", { href: termsHref, target: "_blank", rel: "noopener noreferrer", children: [
|
|
3833
|
-
"\u5229\u7528\u898F\u7D04 (v",
|
|
3834
|
-
termsVersion,
|
|
3835
|
-
")"
|
|
3836
|
-
] }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
3837
|
-
"\u5229\u7528\u898F\u7D04 (v",
|
|
3838
|
-
termsVersion,
|
|
3839
|
-
")"
|
|
3840
|
-
] }),
|
|
3841
|
-
" ",
|
|
3842
|
-
"\u306B\u540C\u610F\u3057\u307E\u3059\u3002"
|
|
3843
|
-
] })
|
|
3844
|
-
]
|
|
3845
|
-
}
|
|
3846
|
-
),
|
|
3847
|
-
/* @__PURE__ */ jsxs("label", { style: { display: "flex", alignItems: "flex-start", gap: SPACING_SM }, children: [
|
|
3913
|
+
/* @__PURE__ */ jsxs("label", { style: s(legalRowLast), className: classNames?.legalRow, children: [
|
|
3848
3914
|
/* @__PURE__ */ jsx(
|
|
3849
3915
|
"input",
|
|
3850
3916
|
{
|
|
3851
3917
|
type: "checkbox",
|
|
3918
|
+
className: classNames?.legalCheckbox,
|
|
3852
3919
|
checked: agreedPrivacy,
|
|
3853
3920
|
onChange: (e) => setAgreedPrivacy(e.target.checked),
|
|
3854
3921
|
required: true
|
|
3855
3922
|
}
|
|
3856
3923
|
),
|
|
3857
|
-
/* @__PURE__ */ jsxs("span", { style:
|
|
3858
|
-
|
|
3859
|
-
|
|
3860
|
-
privacyVersion,
|
|
3861
|
-
")"
|
|
3862
|
-
] }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
3863
|
-
"\u30D7\u30E9\u30A4\u30D0\u30B7\u30FC\u30DD\u30EA\u30B7\u30FC (v",
|
|
3864
|
-
privacyVersion,
|
|
3865
|
-
")"
|
|
3866
|
-
] }),
|
|
3867
|
-
" ",
|
|
3868
|
-
"\u306B\u540C\u610F\u3057\u307E\u3059\u3002"
|
|
3924
|
+
/* @__PURE__ */ jsxs("span", { style: s(spanStyle), children: [
|
|
3925
|
+
renderPrivacyLink(),
|
|
3926
|
+
" \u306B\u540C\u610F\u3057\u307E\u3059\u3002"
|
|
3869
3927
|
] })
|
|
3870
3928
|
] })
|
|
3871
|
-
] }) : /* @__PURE__ */ jsx("div", { style: fieldsetStyle, children: /* @__PURE__ */ jsxs("label", { style:
|
|
3929
|
+
] }) : /* @__PURE__ */ jsx("div", { style: s(fieldsetStyle), className: classNames?.legalBlock, children: /* @__PURE__ */ jsxs("label", { style: s(legalRowLast), className: classNames?.legalRow, children: [
|
|
3872
3930
|
/* @__PURE__ */ jsx(
|
|
3873
3931
|
"input",
|
|
3874
3932
|
{
|
|
3875
3933
|
type: "checkbox",
|
|
3934
|
+
className: classNames?.legalCheckbox,
|
|
3876
3935
|
checked: agreedLegal,
|
|
3877
3936
|
onChange: (e) => setAgreedLegal(e.target.checked),
|
|
3878
3937
|
required: true
|
|
3879
3938
|
}
|
|
3880
3939
|
),
|
|
3881
|
-
/* @__PURE__ */ jsxs("span", { style:
|
|
3882
|
-
|
|
3883
|
-
|
|
3884
|
-
|
|
3885
|
-
|
|
3886
|
-
] }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
3887
|
-
"\u5229\u7528\u898F\u7D04 (v",
|
|
3888
|
-
termsVersion,
|
|
3889
|
-
")"
|
|
3890
|
-
] }),
|
|
3891
|
-
" ",
|
|
3892
|
-
"\u3068",
|
|
3893
|
-
" ",
|
|
3894
|
-
privacyHref ? /* @__PURE__ */ jsxs("a", { href: privacyHref, target: "_blank", rel: "noopener noreferrer", children: [
|
|
3895
|
-
"\u30D7\u30E9\u30A4\u30D0\u30B7\u30FC\u30DD\u30EA\u30B7\u30FC (v",
|
|
3896
|
-
privacyVersion,
|
|
3897
|
-
")"
|
|
3898
|
-
] }) : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
3899
|
-
"\u30D7\u30E9\u30A4\u30D0\u30B7\u30FC\u30DD\u30EA\u30B7\u30FC (v",
|
|
3900
|
-
privacyVersion,
|
|
3901
|
-
")"
|
|
3902
|
-
] }),
|
|
3903
|
-
" ",
|
|
3904
|
-
"\u306B\u540C\u610F\u3057\u307E\u3059\u3002"
|
|
3940
|
+
/* @__PURE__ */ jsxs("span", { style: s(spanStyle), children: [
|
|
3941
|
+
renderTermsLink(),
|
|
3942
|
+
" \u3068 ",
|
|
3943
|
+
renderPrivacyLink(),
|
|
3944
|
+
" \u306B\u540C\u610F\u3057\u307E\u3059\u3002"
|
|
3905
3945
|
] })
|
|
3906
3946
|
] }) }),
|
|
3907
|
-
!isAuth && turnstileSlot && /* @__PURE__ */ jsx("div", { style: fieldsetStyle, children: turnstileSlot }),
|
|
3908
|
-
formError && /* @__PURE__ */ jsx(
|
|
3947
|
+
!isAuth && turnstileSlot && /* @__PURE__ */ jsx("div", { style: s(fieldsetStyle), className: classNames?.field, children: turnstileSlot }),
|
|
3948
|
+
formError && /* @__PURE__ */ jsx(
|
|
3949
|
+
"p",
|
|
3950
|
+
{
|
|
3951
|
+
role: "alert",
|
|
3952
|
+
style: s({ ...errorTextStyle, marginBottom: SPACING_MD }),
|
|
3953
|
+
className: classNames?.errorText,
|
|
3954
|
+
children: formError
|
|
3955
|
+
}
|
|
3956
|
+
),
|
|
3909
3957
|
/* @__PURE__ */ jsx(
|
|
3910
3958
|
"button",
|
|
3911
3959
|
{
|
|
3912
3960
|
type: "submit",
|
|
3913
|
-
style: {
|
|
3961
|
+
style: s({
|
|
3914
3962
|
...submitButtonStyle,
|
|
3915
3963
|
opacity: submitting ? SUBMIT_BUTTON_OPACITY_PENDING : 1,
|
|
3916
3964
|
cursor: submitting ? "not-allowed" : "pointer"
|
|
3917
|
-
},
|
|
3965
|
+
}),
|
|
3966
|
+
className: classNames?.submitButton,
|
|
3918
3967
|
disabled: submitting,
|
|
3919
3968
|
children: submitting ? "\u9001\u4FE1\u4E2D..." : "\u9001\u4FE1\u3059\u308B"
|
|
3920
3969
|
}
|