@drawbridge/components 0.1.0 → 0.1.2
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/advertisement.mjs +4 -4
- package/dist/bridge/advertisements.mjs +3 -3
- package/dist/bridge/fields.mjs +7 -7
- package/dist/bridge/form-subdomain-embed.mjs +9 -9
- package/dist/bridge/form-subdomain-header.mjs +3 -3
- package/dist/bridge/form-subdomain-issue.mjs +10 -10
- package/dist/bridge/form-subdomain-prize.mjs +7 -7
- package/dist/bridge/form-subdomain-shop-modal.mjs +13 -13
- package/dist/bridge/form-subdomain-shop.mjs +1 -1
- package/dist/bridge/form-subdomain.mjs +16 -16
- package/dist/bridge/product-tile.mjs +2 -2
- package/dist/bridge/share-button.mjs +1 -1
- package/dist/bridge/template-layout.mjs +14 -14
- package/dist/bridge/template-modal.mjs +15 -15
- package/dist/bridge/template-not-found.mjs +1 -1
- package/dist/bridge/template-subdomain-gallery.mjs +5 -5
- package/dist/bridge/template-subdomain-link.mjs +1 -1
- package/dist/bridge/template-subdomain.mjs +7 -7
- package/dist/dashboard/accordion.mjs +5 -5
- package/dist/dashboard/card-affiliate.mjs +11 -11
- package/dist/dashboard/card-connection.mjs +5 -5
- package/dist/dashboard/card-integration.mjs +6 -6
- package/dist/dashboard/card-metric.mjs +3 -3
- package/dist/dashboard/card-note.mjs +4 -4
- package/dist/dashboard/card-order.mjs +1 -1
- package/dist/dashboard/card-overage.mjs +4 -4
- package/dist/dashboard/card-payment-method.mjs +1 -1
- package/dist/dashboard/card-plan.mjs +5 -5
- package/dist/dashboard/card-product.mjs +1 -1
- package/dist/dashboard/card-score.mjs +2 -2
- package/dist/dashboard/card-setting.mjs +2 -2
- package/dist/dashboard/card-task.mjs +3 -3
- package/dist/dashboard/card-template.mjs +1 -1
- package/dist/dashboard/card-tile.mjs +7 -7
- package/dist/dashboard/card-utm.mjs +4 -4
- package/dist/dashboard/carousel-tiles.mjs +2 -2
- package/dist/dashboard/code-formatter.mjs +2 -2
- package/dist/dashboard/drawer-subscription.mjs +14 -14
- package/dist/dashboard/drawer.mjs +4 -4
- package/dist/dashboard/dropdown.mjs +4 -4
- package/dist/dashboard/form-action.mjs +4 -4
- package/dist/dashboard/form-address.mjs +6 -6
- package/dist/dashboard/form-admin-campaign.mjs +8 -8
- package/dist/dashboard/form-admin-invoice-refund.mjs +8 -8
- package/dist/dashboard/form-admin-oauth.mjs +11 -11
- package/dist/dashboard/form-admin-organization.mjs +8 -8
- package/dist/dashboard/form-admin-provider.mjs +10 -10
- package/dist/dashboard/form-admin-referrer.mjs +7 -7
- package/dist/dashboard/form-admin-subscription-custom.mjs +11 -11
- package/dist/dashboard/form-admin-template.mjs +11 -11
- package/dist/dashboard/form-admin-user-credit.mjs +7 -7
- package/dist/dashboard/form-admin-user-permissions.mjs +7 -7
- package/dist/dashboard/form-admin-user-status.mjs +7 -7
- package/dist/dashboard/form-admin-utm.mjs +12 -12
- package/dist/dashboard/form-ai.mjs +16 -16
- package/dist/dashboard/form-auth.mjs +11 -11
- package/dist/dashboard/form-credit.mjs +1 -1
- package/dist/dashboard/form-file-upload.mjs +14 -14
- package/dist/dashboard/form-file.mjs +11 -11
- package/dist/dashboard/form-filters-analytics.mjs +9 -9
- package/dist/dashboard/form-filters.mjs +9 -9
- package/dist/dashboard/form-note.mjs +7 -7
- package/dist/dashboard/form-notification.mjs +5 -5
- package/dist/dashboard/form-organization-affiliate.mjs +8 -8
- package/dist/dashboard/form-organization-brand.mjs +9 -9
- package/dist/dashboard/form-organization-campaign-advertisement.mjs +14 -14
- package/dist/dashboard/form-organization-campaign-agreement.mjs +11 -11
- package/dist/dashboard/form-organization-campaign-draw.mjs +12 -12
- package/dist/dashboard/form-organization-campaign-field-email.mjs +10 -10
- package/dist/dashboard/form-organization-campaign-field-name.mjs +7 -7
- package/dist/dashboard/form-organization-campaign-field-number.mjs +8 -8
- package/dist/dashboard/form-organization-campaign-field-phone.mjs +9 -9
- package/dist/dashboard/form-organization-campaign-field-select.mjs +9 -9
- package/dist/dashboard/form-organization-campaign-field-text.mjs +8 -8
- package/dist/dashboard/form-organization-campaign-field-textarea.mjs +8 -8
- package/dist/dashboard/form-organization-campaign-integration-age.mjs +8 -8
- package/dist/dashboard/form-organization-campaign-integration-enable.mjs +5 -5
- package/dist/dashboard/form-organization-campaign-integration-geocode.mjs +9 -9
- package/dist/dashboard/form-organization-campaign-integration-gtm.mjs +8 -8
- package/dist/dashboard/form-organization-campaign-lead.mjs +7 -7
- package/dist/dashboard/form-organization-campaign-link.mjs +11 -11
- package/dist/dashboard/form-organization-campaign-page-affiliates.mjs +6 -6
- package/dist/dashboard/form-organization-campaign-page-embed.mjs +7 -7
- package/dist/dashboard/form-organization-campaign-page-preview.mjs +8 -8
- package/dist/dashboard/form-organization-campaign-page-qr.mjs +14 -14
- package/dist/dashboard/form-organization-campaign-page-share.mjs +15 -15
- package/dist/dashboard/form-organization-campaign-page-slug.mjs +8 -8
- package/dist/dashboard/form-organization-campaign-page.mjs +10 -10
- package/dist/dashboard/form-organization-campaign-prize-edit.mjs +16 -16
- package/dist/dashboard/form-organization-campaign-prize.mjs +7 -7
- package/dist/dashboard/form-organization-campaign-range.mjs +10 -10
- package/dist/dashboard/form-organization-campaign.mjs +13 -13
- package/dist/dashboard/form-organization-connection.mjs +14 -14
- package/dist/dashboard/form-organization-export.mjs +9 -9
- package/dist/dashboard/form-organization-file-frame.mjs +9 -9
- package/dist/dashboard/form-organization-file.mjs +11 -11
- package/dist/dashboard/form-organization-identity.mjs +15 -15
- package/dist/dashboard/form-organization-member.mjs +9 -9
- package/dist/dashboard/form-organization-segment.mjs +12 -12
- package/dist/dashboard/form-organization-workflow.mjs +18 -18
- package/dist/dashboard/form-organization.mjs +11 -11
- package/dist/dashboard/form-otc.mjs +7 -7
- package/dist/dashboard/form-payment-methods.mjs +7 -7
- package/dist/dashboard/form-profile.mjs +7 -7
- package/dist/dashboard/form-stripe-promotion.mjs +7 -7
- package/dist/dashboard/form-stripe.mjs +5 -5
- package/dist/dashboard/form-verify-prize.mjs +13 -13
- package/dist/dashboard/google.mjs +5 -5
- package/dist/dashboard/guard-navigation.mjs +3 -3
- package/dist/dashboard/guide.mjs +4 -4
- package/dist/dashboard/iframe.mjs +1 -1
- package/dist/dashboard/input-address-saved.mjs +7 -7
- package/dist/dashboard/input-array.mjs +5 -5
- package/dist/dashboard/input-color.mjs +2 -2
- package/dist/dashboard/input-combobox.mjs +5 -5
- package/dist/dashboard/input-date.mjs +4 -4
- package/dist/dashboard/input-editor.mjs +6 -6
- package/dist/dashboard/input-fields.mjs +20 -20
- package/dist/dashboard/input-file.mjs +6 -6
- package/dist/dashboard/input-font.mjs +6 -6
- package/dist/dashboard/input-group-ai.mjs +5 -5
- package/dist/dashboard/input-radio.mjs +2 -2
- package/dist/dashboard/input-resource.mjs +5 -5
- package/dist/dashboard/input-secret.mjs +6 -6
- package/dist/dashboard/input-time.mjs +2 -2
- package/dist/dashboard/lib/table-actions.mjs +1 -1
- package/dist/dashboard/lib/uppy.mjs +1 -1
- package/dist/dashboard/link-back.mjs +4 -4
- package/dist/dashboard/link.mjs +1 -1
- package/dist/dashboard/list-resource.mjs +4 -4
- package/dist/dashboard/list.mjs +3 -3
- package/dist/dashboard/menu.js +65 -9
- package/dist/dashboard/menu.mjs +76 -21
- package/dist/dashboard/modal.mjs +5 -5
- package/dist/dashboard/notes.mjs +7 -7
- package/dist/dashboard/notice.mjs +3 -3
- package/dist/dashboard/paged.mjs +7 -7
- package/dist/dashboard/provider-resource.mjs +2 -2
- package/dist/dashboard/provider-ui.mjs +6 -6
- package/dist/dashboard/provider.mjs +1 -1
- package/dist/dashboard/recharts.mjs +1 -1
- package/dist/dashboard/steps.mjs +6 -6
- package/dist/dashboard/swatch.mjs +3 -3
- package/dist/dashboard/table-cell-title.mjs +6 -6
- package/dist/dashboard/table.mjs +15 -15
- package/dist/dashboard/template-dashboard.mjs +13 -13
- package/dist/dashboard/template-not-found.mjs +3 -3
- package/dist/dashboard/template-socket.mjs +3 -3
- package/dist/dashboard/template-suspended.mjs +1 -1
- package/dist/dashboard/template-ui.js +4 -1
- package/dist/dashboard/template-ui.mjs +16 -13
- package/dist/dashboard/wrapper-ai.mjs +1 -1
- package/dist/icons/social.mjs +14 -14
- package/dist/input-checkbox.mjs +3 -3
- package/dist/input-group.mjs +2 -2
- package/dist/input-name.mjs +2 -2
- package/dist/input-number.mjs +4 -4
- package/dist/input-phone.mjs +2 -2
- package/dist/input-select.mjs +2 -2
- package/dist/input-text.mjs +1 -1
- package/dist/input-textarea.mjs +1 -1
- package/dist/product.mjs +6 -6
- package/dist/provider-font.mjs +1 -1
- package/dist/shared/badge.mjs +1 -1
- package/dist/shared/button.mjs +2 -2
- package/dist/shared/card-asset.mjs +3 -3
- package/dist/shared/card-prize.mjs +4 -4
- package/dist/shared/carousel.mjs +2 -2
- package/dist/shared/copy-to-clipboard.mjs +4 -4
- package/dist/shared/empty.mjs +1 -1
- package/dist/shared/error.mjs +1 -1
- package/dist/shared/fieldset.mjs +1 -1
- package/dist/shared/input-checkbox-list.mjs +3 -3
- package/dist/shared/input-range.mjs +1 -1
- package/dist/shared/input-switch.mjs +2 -2
- package/dist/shared/input-url.mjs +1 -1
- package/dist/shared/lib/helpers.mjs +2 -2
- package/dist/shared/lib/icon-labels.mjs +7 -7
- package/dist/shared/lib/yup.mjs +1 -1
- package/dist/shared/loader.mjs +2 -2
- package/dist/shared/overlay.mjs +2 -2
- package/dist/shared/sortable.mjs +1 -1
- package/dist/shared/tabs.mjs +3 -3
- package/dist/video.mjs +2 -2
- package/package.json +299 -3
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Fragment, useCallback, useState } from "react";
|
|
3
3
|
import { useQueryClient } from "@tanstack/react-query";
|
|
4
|
-
import ProviderResource from "./provider-resource";
|
|
5
|
-
import InputGroup from "../input-group";
|
|
6
|
-
import InputRadio from "./input-radio";
|
|
7
|
-
import CardPaymentMethod from "./card-payment-method";
|
|
8
|
-
import Empty from "../shared/empty";
|
|
9
|
-
import { useModal } from "./lib/hooks";
|
|
10
|
-
import Button from "../shared/button";
|
|
4
|
+
import ProviderResource from "./provider-resource.mjs";
|
|
5
|
+
import InputGroup from "../input-group.mjs";
|
|
6
|
+
import InputRadio from "./input-radio.mjs";
|
|
7
|
+
import CardPaymentMethod from "./card-payment-method.mjs";
|
|
8
|
+
import Empty from "../shared/empty.mjs";
|
|
9
|
+
import { useModal } from "./lib/hooks.mjs";
|
|
10
|
+
import Button from "../shared/button.mjs";
|
|
11
11
|
const FormPaymentMethods = ({
|
|
12
12
|
onChange,
|
|
13
13
|
onClickAdd,
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
-
import { useForm, Controller } from "../shared/lib/form";
|
|
3
|
+
import { useForm, Controller } from "../shared/lib/form.mjs";
|
|
4
4
|
import { request } from "@drawbridge/drawbridge-utils/fetch";
|
|
5
|
-
import yup, { resolver } from "../shared/lib/yup";
|
|
6
|
-
import Form from "../shared/form";
|
|
7
|
-
import Fieldset from "../shared/fieldset";
|
|
8
|
-
import InputGroup from "../input-group";
|
|
9
|
-
import InputText from "../input-text";
|
|
10
|
-
import Button from "../shared/button";
|
|
5
|
+
import yup, { resolver } from "../shared/lib/yup.mjs";
|
|
6
|
+
import Form from "../shared/form.mjs";
|
|
7
|
+
import Fieldset from "../shared/fieldset.mjs";
|
|
8
|
+
import InputGroup from "../input-group.mjs";
|
|
9
|
+
import InputText from "../input-text.mjs";
|
|
10
|
+
import Button from "../shared/button.mjs";
|
|
11
11
|
const FormProfileEmail = ({
|
|
12
12
|
onError,
|
|
13
13
|
onSuccess,
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { request } from "@drawbridge/drawbridge-utils/fetch";
|
|
3
|
-
import { useForm, Controller } from "../shared/lib/form";
|
|
4
|
-
import yup, { resolver } from "../shared/lib/yup";
|
|
5
|
-
import Form from "../shared/form";
|
|
6
|
-
import Fieldset from "../shared/fieldset";
|
|
7
|
-
import InputGroup from "../input-group";
|
|
8
|
-
import InputText from "../input-text";
|
|
9
|
-
import Button from "../shared/button";
|
|
3
|
+
import { useForm, Controller } from "../shared/lib/form.mjs";
|
|
4
|
+
import yup, { resolver } from "../shared/lib/yup.mjs";
|
|
5
|
+
import Form from "../shared/form.mjs";
|
|
6
|
+
import Fieldset from "../shared/fieldset.mjs";
|
|
7
|
+
import InputGroup from "../input-group.mjs";
|
|
8
|
+
import InputText from "../input-text.mjs";
|
|
9
|
+
import Button from "../shared/button.mjs";
|
|
10
10
|
const FormStripePromotion = ({
|
|
11
11
|
onSuccess,
|
|
12
12
|
plan
|
|
@@ -4,11 +4,11 @@ import { request } from "@drawbridge/drawbridge-utils/fetch";
|
|
|
4
4
|
import { loadStripe } from "@stripe/stripe-js";
|
|
5
5
|
import { usePathname } from "next/navigation";
|
|
6
6
|
import { useStripe, useElements, AddressElement, Elements, PaymentElement } from "@stripe/react-stripe-js";
|
|
7
|
-
import Form from "../shared/form";
|
|
8
|
-
import Fieldset from "../shared/fieldset";
|
|
9
|
-
import Empty from "../shared/empty";
|
|
10
|
-
import CardTask from "./card-task";
|
|
11
|
-
import Button from "../shared/button";
|
|
7
|
+
import Form from "../shared/form.mjs";
|
|
8
|
+
import Fieldset from "../shared/fieldset.mjs";
|
|
9
|
+
import Empty from "../shared/empty.mjs";
|
|
10
|
+
import CardTask from "./card-task.mjs";
|
|
11
|
+
import Button from "../shared/button.mjs";
|
|
12
12
|
const stripe = loadStripe(process.env.NEXT_PUBLIC_STRIPE_API_KEY);
|
|
13
13
|
const FormStripeInner = ({
|
|
14
14
|
button,
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
-
import Link from "./link";
|
|
4
|
-
import { useForm, FormProvider, Controller } from "../shared/lib/form";
|
|
3
|
+
import Link from "./link.mjs";
|
|
4
|
+
import { useForm, FormProvider, Controller } from "../shared/lib/form.mjs";
|
|
5
5
|
import { useQueryClient } from "@tanstack/react-query";
|
|
6
|
-
import yup, { resolver } from "../shared/lib/yup";
|
|
7
|
-
import { useModal } from "./lib/hooks";
|
|
6
|
+
import yup, { resolver } from "../shared/lib/yup.mjs";
|
|
7
|
+
import { useModal } from "./lib/hooks.mjs";
|
|
8
8
|
import { request } from "@drawbridge/drawbridge-utils/fetch";
|
|
9
|
-
import Form from "../shared/form";
|
|
10
|
-
import Fieldset from "../shared/fieldset";
|
|
11
|
-
import FormAction from "./form-action";
|
|
12
|
-
import InputGroup from "../input-group";
|
|
13
|
-
import InputText from "../input-text";
|
|
14
|
-
import InputCombobox from "./input-combobox";
|
|
15
|
-
import AddressLines from "../shared/address-lines";
|
|
16
|
-
import CardDataItem from "./card-data-item";
|
|
17
|
-
import Button from "../shared/button";
|
|
9
|
+
import Form from "../shared/form.mjs";
|
|
10
|
+
import Fieldset from "../shared/fieldset.mjs";
|
|
11
|
+
import FormAction from "./form-action.mjs";
|
|
12
|
+
import InputGroup from "../input-group.mjs";
|
|
13
|
+
import InputText from "../input-text.mjs";
|
|
14
|
+
import InputCombobox from "./input-combobox.mjs";
|
|
15
|
+
import AddressLines from "../shared/address-lines.mjs";
|
|
16
|
+
import CardDataItem from "./card-data-item.mjs";
|
|
17
|
+
import Button from "../shared/button.mjs";
|
|
18
18
|
const addressFieldNames = ["address", "address2", "city", "country", "postal", "province"];
|
|
19
19
|
const buildFieldsSchema = (fields) => {
|
|
20
20
|
return (fields || []).reduce(
|
|
@@ -3,11 +3,11 @@ import { jsx, jsxs } from "react/jsx-runtime";
|
|
|
3
3
|
import { useCallback, useEffect, useRef, useState } from "react";
|
|
4
4
|
import { useQueryClient } from "@tanstack/react-query";
|
|
5
5
|
import { APIProvider, ColorScheme, ControlPosition, Map, MapControl, useMap, useMapsLibrary } from "@vis.gl/react-google-maps";
|
|
6
|
-
import Home from "../icons/home";
|
|
7
|
-
import LoaderIcon from "../icons/loader";
|
|
8
|
-
import InputText from "../input-text";
|
|
9
|
-
import Button from "../shared/button";
|
|
10
|
-
import { getLocation, toAddressPayload } from "./lib/geo";
|
|
6
|
+
import Home from "../icons/home.mjs";
|
|
7
|
+
import LoaderIcon from "../icons/loader.mjs";
|
|
8
|
+
import InputText from "../input-text.mjs";
|
|
9
|
+
import Button from "../shared/button.mjs";
|
|
10
|
+
import { getLocation, toAddressPayload } from "./lib/geo.mjs";
|
|
11
11
|
let timeout;
|
|
12
12
|
const InputGoogleAutocomplete = ({
|
|
13
13
|
fields = ["displayName", "formattedAddress", "location", "addressComponents"],
|
|
@@ -3,9 +3,9 @@ import { jsx } from "react/jsx-runtime";
|
|
|
3
3
|
import { useCallback, useEffect, useRef, useState } from "react";
|
|
4
4
|
import { useRouter } from "next/navigation";
|
|
5
5
|
import { useQuery, useQueryClient } from "@tanstack/react-query";
|
|
6
|
-
import { interceptHref } from "./lib/navigation";
|
|
7
|
-
import FormAction from "./form-action";
|
|
8
|
-
import Modal from "./modal";
|
|
6
|
+
import { interceptHref } from "./lib/navigation.mjs";
|
|
7
|
+
import FormAction from "./form-action.mjs";
|
|
8
|
+
import Modal from "./modal.mjs";
|
|
9
9
|
const trap = () => window.history.pushState({ guard: true }, "", window.location.href);
|
|
10
10
|
const releaseTrap = () => {
|
|
11
11
|
var _a;
|
package/dist/dashboard/guide.mjs
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { forwardRef } from "react";
|
|
3
3
|
import dynamic from "next/dynamic";
|
|
4
|
-
import Times from "../icons/times";
|
|
5
|
-
import Button from "../shared/button";
|
|
4
|
+
import Times from "../icons/times.mjs";
|
|
5
|
+
import Button from "../shared/button.mjs";
|
|
6
6
|
const Joyride = dynamic(() => import("react-joyride"), { ssr: false });
|
|
7
|
-
const Video = dynamic(() => import("../video"), { ssr: false });
|
|
8
|
-
import WrapperGradient from "../wrapper-gradient";
|
|
7
|
+
const Video = dynamic(() => import("../video.mjs"), { ssr: false });
|
|
8
|
+
import WrapperGradient from "../wrapper-gradient.mjs";
|
|
9
9
|
const Beacon = forwardRef((props, ref) => {
|
|
10
10
|
return /* @__PURE__ */ jsx(
|
|
11
11
|
Button,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { forwardRef, useLayoutEffect, useRef, useState } from "react";
|
|
4
|
-
import LoaderComponent from "../shared/loader";
|
|
4
|
+
import LoaderComponent from "../shared/loader.mjs";
|
|
5
5
|
const CONTENT_WIDTH = 390;
|
|
6
6
|
const CONTENT_HEIGHT = 693;
|
|
7
7
|
const POSITION_STYLES = {
|
|
@@ -3,13 +3,13 @@ import { jsx, jsxs } from "react/jsx-runtime";
|
|
|
3
3
|
import { useFormContext, useWatch } from "react-hook-form";
|
|
4
4
|
import { useQueryClient } from "@tanstack/react-query";
|
|
5
5
|
import { request } from "@drawbridge/drawbridge-utils/fetch";
|
|
6
|
-
import { useModal, useDrawer } from "./lib/hooks";
|
|
7
|
-
import { InputArrayButton, InputArrayControl } from "./input-array";
|
|
8
|
-
import ListResource from "./list-resource";
|
|
9
|
-
import AddressLines from "../shared/address-lines";
|
|
10
|
-
import CardDataItem from "./card-data-item";
|
|
11
|
-
import FormAddress from "./form-address";
|
|
12
|
-
import Trash from "../icons/trash";
|
|
6
|
+
import { useModal, useDrawer } from "./lib/hooks.mjs";
|
|
7
|
+
import { InputArrayButton, InputArrayControl } from "./input-array.mjs";
|
|
8
|
+
import ListResource from "./list-resource.mjs";
|
|
9
|
+
import AddressLines from "../shared/address-lines.mjs";
|
|
10
|
+
import CardDataItem from "./card-data-item.mjs";
|
|
11
|
+
import FormAddress from "./form-address.mjs";
|
|
12
|
+
import Trash from "../icons/trash.mjs";
|
|
13
13
|
const addressFieldNames = ["address", "address2", "city", "country", "postal", "province"];
|
|
14
14
|
const InputAddressSaved = () => {
|
|
15
15
|
const queryClient = useQueryClient();
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useFieldArray } from "react-hook-form";
|
|
3
|
-
import Sortable from "../shared/sortable";
|
|
4
|
-
import Plus from "../icons/plus";
|
|
5
|
-
import Trash from "../icons/trash";
|
|
6
|
-
import Empty from "../shared/empty";
|
|
7
|
-
import Button from "../shared/button";
|
|
3
|
+
import Sortable from "../shared/sortable.mjs";
|
|
4
|
+
import Plus from "../icons/plus.mjs";
|
|
5
|
+
import Trash from "../icons/trash.mjs";
|
|
6
|
+
import Empty from "../shared/empty.mjs";
|
|
7
|
+
import Button from "../shared/button.mjs";
|
|
8
8
|
import { Fragment } from "react";
|
|
9
9
|
const InputArrayButton = ({
|
|
10
10
|
onClick,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useEffect, useState } from "react";
|
|
3
3
|
import { useQueryClient } from "@tanstack/react-query";
|
|
4
|
-
import { useModal } from "./lib/hooks";
|
|
4
|
+
import { useModal } from "./lib/hooks.mjs";
|
|
5
5
|
import { HexColorInput, HexColorPicker } from "react-colorful";
|
|
6
6
|
import tinycolor from "tinycolor2";
|
|
7
|
-
import Button from "../shared/button";
|
|
7
|
+
import Button from "../shared/button.mjs";
|
|
8
8
|
const colorFormatted = (value) => {
|
|
9
9
|
const color = tinycolor(value);
|
|
10
10
|
const attributes = {
|
|
@@ -8,11 +8,11 @@ import {
|
|
|
8
8
|
ComboboxOption,
|
|
9
9
|
ComboboxOptions
|
|
10
10
|
} from "@headlessui/react";
|
|
11
|
-
import ChevronDown from "../icons/chevron-down";
|
|
12
|
-
import ChevronUp from "../icons/chevron-up";
|
|
13
|
-
import CardAsset from "../shared/card-asset";
|
|
14
|
-
import Badge from "../shared/badge";
|
|
15
|
-
import Button from "../shared/button";
|
|
11
|
+
import ChevronDown from "../icons/chevron-down.mjs";
|
|
12
|
+
import ChevronUp from "../icons/chevron-up.mjs";
|
|
13
|
+
import CardAsset from "../shared/card-asset.mjs";
|
|
14
|
+
import Badge from "../shared/badge.mjs";
|
|
15
|
+
import Button from "../shared/button.mjs";
|
|
16
16
|
const InputCombobox = ({
|
|
17
17
|
disabled = false,
|
|
18
18
|
onChange,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { DayPicker } from "react-day-picker";
|
|
4
|
-
import ChevronLeft from "../icons/chevron-left";
|
|
5
|
-
import ChevronRight from "../icons/chevron-right";
|
|
6
|
-
import InputTime from "./input-time";
|
|
7
|
-
import { toTimeSlot } from "./lib/time-slots";
|
|
4
|
+
import ChevronLeft from "../icons/chevron-left.mjs";
|
|
5
|
+
import ChevronRight from "../icons/chevron-right.mjs";
|
|
6
|
+
import InputTime from "./input-time.mjs";
|
|
7
|
+
import { toTimeSlot } from "./lib/time-slots.mjs";
|
|
8
8
|
const DAY_PICKER_COMPONENTS = {
|
|
9
9
|
Chevron: ({ orientation, ...props }) => {
|
|
10
10
|
const Icon = orientation === "left" ? ChevronLeft : ChevronRight;
|
|
@@ -36,12 +36,12 @@ const Variable = Node.create({
|
|
|
36
36
|
return { dom };
|
|
37
37
|
}
|
|
38
38
|
});
|
|
39
|
-
import Dropdown from "./dropdown";
|
|
40
|
-
import Bold from "../icons/bold";
|
|
41
|
-
import Italic from "../icons/italic";
|
|
42
|
-
import LinkIcon from "../icons/link";
|
|
43
|
-
import Button from "../shared/button";
|
|
44
|
-
import ChevronDown from "../icons/chevron-down";
|
|
39
|
+
import Dropdown from "./dropdown.mjs";
|
|
40
|
+
import Bold from "../icons/bold.mjs";
|
|
41
|
+
import Italic from "../icons/italic.mjs";
|
|
42
|
+
import LinkIcon from "../icons/link.mjs";
|
|
43
|
+
import Button from "../shared/button.mjs";
|
|
44
|
+
import ChevronDown from "../icons/chevron-down.mjs";
|
|
45
45
|
const linkHref = (node) => {
|
|
46
46
|
var _a;
|
|
47
47
|
return (node == null ? void 0 : node.isText) && ((_a = node.marks.find((mark) => mark.type.name === "link")) == null ? void 0 : _a.attrs.href);
|
|
@@ -4,26 +4,26 @@ import { useFormContext, Controller, useWatch } from "react-hook-form";
|
|
|
4
4
|
import { useQueryClient } from "@tanstack/react-query";
|
|
5
5
|
import dynamic from "next/dynamic";
|
|
6
6
|
import { constants } from "@drawbridge/drawbridge-utils";
|
|
7
|
-
import yup from "../shared/lib/yup";
|
|
8
|
-
import Fieldset from "../shared/fieldset";
|
|
9
|
-
import InputGroup from "../input-group";
|
|
10
|
-
import InputGroupAI from "./input-group-ai";
|
|
11
|
-
import InputColor from "./input-color";
|
|
12
|
-
import InputFont from "./input-font";
|
|
13
|
-
import InputRange from "../shared/input-range";
|
|
14
|
-
import InputCombobox from "./input-combobox";
|
|
15
|
-
import InputText from "../input-text";
|
|
16
|
-
import InputTextarea from "../input-textarea";
|
|
17
|
-
import { InputArrayControl, InputArraySortable } from "./input-array";
|
|
18
|
-
import InputFile from "./input-file";
|
|
19
|
-
import Divider from "../shared/divider";
|
|
20
|
-
import Button from "../shared/button";
|
|
21
|
-
import MapPin from "../icons/map-pin";
|
|
22
|
-
import Plus from "../icons/plus";
|
|
23
|
-
import Trash from "../icons/trash";
|
|
24
|
-
const InputGoogleAutocomplete = dynamic(() => import("./google").then((m) => m.InputGoogleAutocomplete), { loading: () => /* @__PURE__ */ jsx(LoaderDynamic, {}), ssr: false });
|
|
25
|
-
import { getLocation, reverseGeocode } from "./lib/geo";
|
|
26
|
-
import { LoaderDynamic } from "../shared/loader";
|
|
7
|
+
import yup from "../shared/lib/yup.mjs";
|
|
8
|
+
import Fieldset from "../shared/fieldset.mjs";
|
|
9
|
+
import InputGroup from "../input-group.mjs";
|
|
10
|
+
import InputGroupAI from "./input-group-ai.mjs";
|
|
11
|
+
import InputColor from "./input-color.mjs";
|
|
12
|
+
import InputFont from "./input-font.mjs";
|
|
13
|
+
import InputRange from "../shared/input-range.mjs";
|
|
14
|
+
import InputCombobox from "./input-combobox.mjs";
|
|
15
|
+
import InputText from "../input-text.mjs";
|
|
16
|
+
import InputTextarea from "../input-textarea.mjs";
|
|
17
|
+
import { InputArrayControl, InputArraySortable } from "./input-array.mjs";
|
|
18
|
+
import InputFile from "./input-file.mjs";
|
|
19
|
+
import Divider from "../shared/divider.mjs";
|
|
20
|
+
import Button from "../shared/button.mjs";
|
|
21
|
+
import MapPin from "../icons/map-pin.mjs";
|
|
22
|
+
import Plus from "../icons/plus.mjs";
|
|
23
|
+
import Trash from "../icons/trash.mjs";
|
|
24
|
+
const InputGoogleAutocomplete = dynamic(() => import("./google.mjs").then((m) => m.InputGoogleAutocomplete), { loading: () => /* @__PURE__ */ jsx(LoaderDynamic, {}), ssr: false });
|
|
25
|
+
import { getLocation, reverseGeocode } from "./lib/geo.mjs";
|
|
26
|
+
import { LoaderDynamic } from "../shared/loader.mjs";
|
|
27
27
|
const schemas = {
|
|
28
28
|
// The one address rule, the same shape every api address route checks
|
|
29
29
|
// (utils yup). Its unit is nullable: a saved empty unit comes back null.
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useQueryClient } from "@tanstack/react-query";
|
|
3
|
-
import { useModal } from "./lib/hooks";
|
|
4
|
-
import FormFile from "./form-file";
|
|
5
|
-
import CardAsset from "../shared/card-asset";
|
|
6
|
-
import Upload from "../icons/upload";
|
|
7
|
-
import Trash from "../icons/trash";
|
|
8
|
-
import Button from "../shared/button";
|
|
3
|
+
import { useModal } from "./lib/hooks.mjs";
|
|
4
|
+
import FormFile from "./form-file.mjs";
|
|
5
|
+
import CardAsset from "../shared/card-asset.mjs";
|
|
6
|
+
import Upload from "../icons/upload.mjs";
|
|
7
|
+
import Trash from "../icons/trash.mjs";
|
|
8
|
+
import Button from "../shared/button.mjs";
|
|
9
9
|
const InputFile = ({
|
|
10
10
|
button = {},
|
|
11
11
|
disabled,
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useCallback, useEffect, useMemo, useRef, useState } from "react";
|
|
3
3
|
import { useQueryClient } from "@tanstack/react-query";
|
|
4
|
-
import { useModal } from "./lib/hooks";
|
|
5
|
-
import InputCombobox from "./input-combobox";
|
|
6
|
-
import Empty from "../shared/empty";
|
|
7
|
-
import Button from "../shared/button";
|
|
8
|
-
import InputSelect from "../input-select";
|
|
9
|
-
import ChevronUpDown from "../icons/chevron-up-down";
|
|
4
|
+
import { useModal } from "./lib/hooks.mjs";
|
|
5
|
+
import InputCombobox from "./input-combobox.mjs";
|
|
6
|
+
import Empty from "../shared/empty.mjs";
|
|
7
|
+
import Button from "../shared/button.mjs";
|
|
8
|
+
import InputSelect from "../input-select.mjs";
|
|
9
|
+
import ChevronUpDown from "../icons/chevron-up-down.mjs";
|
|
10
10
|
const defaults = {
|
|
11
11
|
family: "Roboto Flex",
|
|
12
12
|
transform: "none",
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useQueryClient } from "@tanstack/react-query";
|
|
3
|
-
import { FormAiText } from "./form-ai";
|
|
4
|
-
import Error from "../shared/error";
|
|
5
|
-
import Sparkles from "../icons/sparkles";
|
|
6
|
-
import Button from "../shared/button";
|
|
7
|
-
import { useDrawer } from "./lib/hooks";
|
|
3
|
+
import { FormAiText } from "./form-ai.mjs";
|
|
4
|
+
import Error from "../shared/error.mjs";
|
|
5
|
+
import Sparkles from "../icons/sparkles.mjs";
|
|
6
|
+
import Button from "../shared/button.mjs";
|
|
7
|
+
import { useDrawer } from "./lib/hooks.mjs";
|
|
8
8
|
const InputGroupAI = ({
|
|
9
9
|
className,
|
|
10
10
|
error,
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import React, { useEffect, useRef } from "react";
|
|
4
4
|
import { useQueryClient } from "@tanstack/react-query";
|
|
5
|
-
import { useModal } from "./lib/hooks";
|
|
6
|
-
import { InputArrayButton } from "./input-array";
|
|
7
|
-
import Trash from "../icons/trash";
|
|
8
|
-
import ListResource from "./list-resource";
|
|
9
|
-
import { withArticle } from "../shared/lib/helpers";
|
|
5
|
+
import { useModal } from "./lib/hooks.mjs";
|
|
6
|
+
import { InputArrayButton } from "./input-array.mjs";
|
|
7
|
+
import Trash from "../icons/trash.mjs";
|
|
8
|
+
import ListResource from "./list-resource.mjs";
|
|
9
|
+
import { withArticle } from "../shared/lib/helpers.mjs";
|
|
10
10
|
const InputResourceSingle = ({
|
|
11
11
|
empty,
|
|
12
12
|
endpoint,
|
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { useState } from "react";
|
|
4
4
|
import { useQueryClient } from "@tanstack/react-query";
|
|
5
|
-
import { useModal } from "./lib/hooks";
|
|
6
|
-
import InputGroup from "../input-group";
|
|
7
|
-
import InputText from "../input-text";
|
|
8
|
-
import CopyToClipboard from "../shared/copy-to-clipboard";
|
|
9
|
-
import Button from "../shared/button";
|
|
10
|
-
import { FormOtcConfirm } from "./form-otc";
|
|
5
|
+
import { useModal } from "./lib/hooks.mjs";
|
|
6
|
+
import InputGroup from "../input-group.mjs";
|
|
7
|
+
import InputText from "../input-text.mjs";
|
|
8
|
+
import CopyToClipboard from "../shared/copy-to-clipboard.mjs";
|
|
9
|
+
import Button from "../shared/button.mjs";
|
|
10
|
+
import { FormOtcConfirm } from "./form-otc.mjs";
|
|
11
11
|
const InputSecret = ({
|
|
12
12
|
cleared = false,
|
|
13
13
|
field,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
-
import InputSelect from "../input-select";
|
|
4
|
-
import { HOURS, MINUTES, PERIODS, isPastSlot } from "./lib/time-slots";
|
|
3
|
+
import InputSelect from "../input-select.mjs";
|
|
4
|
+
import { HOURS, MINUTES, PERIODS, isPastSlot } from "./lib/time-slots.mjs";
|
|
5
5
|
const InputTime = ({
|
|
6
6
|
date,
|
|
7
7
|
disabled,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { megabyte } from "@drawbridge/drawbridge-utils";
|
|
2
2
|
import { uploadPartSize } from "@drawbridge/drawbridge-utils/upload";
|
|
3
3
|
import { request } from "@drawbridge/drawbridge-utils/fetch";
|
|
4
|
-
import { fileMimes, fileParts, fileSizeLimits } from "../../shared/lib/helpers";
|
|
4
|
+
import { fileMimes, fileParts, fileSizeLimits } from "../../shared/lib/helpers.mjs";
|
|
5
5
|
const partSizeFor = uploadPartSize;
|
|
6
6
|
const guard = (event) => {
|
|
7
7
|
if (!isUploading(instance)) return;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { Fragment, useContext } from "react";
|
|
4
|
-
import Link from "./link";
|
|
5
|
-
import ArrowLeft from "../icons/arrow-left";
|
|
6
|
-
import Button from "../shared/button";
|
|
7
|
-
import { FormScope } from "../shared/lib/form";
|
|
4
|
+
import Link from "./link.mjs";
|
|
5
|
+
import ArrowLeft from "../icons/arrow-left.mjs";
|
|
6
|
+
import Button from "../shared/button.mjs";
|
|
7
|
+
import { FormScope } from "../shared/lib/form.mjs";
|
|
8
8
|
const LinkBack = ({
|
|
9
9
|
children,
|
|
10
10
|
element = Link,
|
package/dist/dashboard/link.mjs
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { useEffect, useState, useSyncExternalStore } from "react";
|
|
4
4
|
import NextLink, { useLinkStatus } from "next/link";
|
|
5
|
-
import { trickle } from "./lib/trickle";
|
|
5
|
+
import { trickle } from "./lib/trickle.mjs";
|
|
6
6
|
let waiting = 0;
|
|
7
7
|
const listeners = /* @__PURE__ */ new Set();
|
|
8
8
|
const notify = () => listeners.forEach((listener) => listener());
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
3
|
import React from "react";
|
|
4
|
-
import Paged from "./paged";
|
|
5
|
-
import Empty from "../shared/empty";
|
|
6
|
-
import Button from "../shared/button";
|
|
7
|
-
import InputText from "../input-text";
|
|
4
|
+
import Paged from "./paged.mjs";
|
|
5
|
+
import Empty from "../shared/empty.mjs";
|
|
6
|
+
import Button from "../shared/button.mjs";
|
|
7
|
+
import InputText from "../input-text.mjs";
|
|
8
8
|
const pluralize = (model) => model + (/(s|x|z|ch|sh)$/.test(model) ? "es" : "s");
|
|
9
9
|
const ListResource = ({
|
|
10
10
|
empty,
|
package/dist/dashboard/list.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { Fragment } from "react";
|
|
3
3
|
import { usePathname } from "next/navigation";
|
|
4
|
-
import Link from "./link";
|
|
5
|
-
import Button from "../shared/button";
|
|
6
|
-
import ArrowRight from "../icons/arrow-right";
|
|
4
|
+
import Link from "./link.mjs";
|
|
5
|
+
import Button from "../shared/button.mjs";
|
|
6
|
+
import ArrowRight from "../icons/arrow-right.mjs";
|
|
7
7
|
const List = ({
|
|
8
8
|
className = "space-y-4",
|
|
9
9
|
items = [],
|