firstly 0.0.13 → 0.0.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +16 -0
- package/esm/ROUTES.d.ts +2 -0
- package/esm/ROUTES.js +1 -0
- package/esm/auth/AuthController.d.ts +12 -23
- package/esm/auth/AuthController.js +12 -31
- package/esm/auth/server/AuthController.server.d.ts +11 -11
- package/esm/auth/server/AuthController.server.js +84 -18
- package/esm/auth/server/helperFirstly.d.ts +1 -1
- package/esm/auth/server/helperFirstly.js +1 -0
- package/esm/auth/server/module.d.ts +4 -7
- package/esm/auth/server/module.js +1 -1
- package/esm/auth/server/providers/github.d.ts +2 -1
- package/esm/auth/server/providers/github.js +1 -1
- package/esm/auth/static/assets/Page-B1GE_oYi.d.ts +6 -0
- package/esm/auth/static/assets/Page-B1GE_oYi.js +1 -0
- package/esm/auth/static/assets/Page-CDHFtYuN.d.ts +6 -0
- package/esm/auth/static/assets/Page-CDHFtYuN.js +1 -0
- package/esm/auth/static/assets/Page-Dh8pvAo6.d.ts +6 -0
- package/esm/auth/static/assets/Page-Dh8pvAo6.js +20 -0
- package/esm/auth/static/assets/Page-mK42zGEw.css +1 -0
- package/esm/auth/static/assets/index-7Nh2ct-y.d.ts +151 -0
- package/esm/auth/static/assets/index-7Nh2ct-y.js +42 -0
- package/esm/auth/static/index.html +3 -3
- package/esm/auth/types.d.ts +26 -3
- package/esm/bin/cmd.js +343 -143
- package/esm/changeLog/server/index.d.ts +1 -1
- package/esm/changeLog/server/index.js +1 -1
- package/esm/cron/server/index.d.ts +1 -1
- package/esm/cron/server/index.js +1 -1
- package/esm/feedback/FeedbackController.js +57 -51
- package/esm/feedback/server/index.d.ts +7 -16
- package/esm/feedback/server/index.js +5 -6
- package/esm/feedback/types.d.ts +14 -0
- package/esm/feedback/types.js +4 -0
- package/esm/feedback/ui/DialogIssue.svelte +78 -62
- package/esm/feedback/ui/DialogIssue.svelte.d.ts +20 -18
- package/esm/feedback/ui/DialogIssues.svelte +37 -28
- package/esm/feedback/ui/DialogIssues.svelte.d.ts +20 -18
- package/esm/feedback/ui/DialogMilestones.svelte +18 -12
- package/esm/feedback/ui/DialogMilestones.svelte.d.ts +18 -16
- package/esm/feedback/ui/Feedback.svelte +11 -9
- package/esm/feedback/ui/Feedback.svelte.d.ts +16 -14
- package/esm/mail/server/index.d.ts +9 -2
- package/esm/mail/server/index.js +6 -2
- package/esm/mail/templates/DefaultMail.svelte +64 -44
- package/esm/mail/templates/DefaultMail.svelte.d.ts +28 -26
- package/esm/{api → server}/index.d.ts +8 -0
- package/esm/storeItem.d.ts +1 -1
- package/esm/storeList.d.ts +1 -1
- package/esm/sveltekit/server/index.d.ts +1 -10
- package/esm/sveltekit/server/index.js +1 -1
- package/esm/ui/Button.svelte +79 -56
- package/esm/ui/Button.svelte.d.ts +34 -24
- package/esm/ui/Clipboardable.svelte +18 -11
- package/esm/ui/Clipboardable.svelte.d.ts +34 -23
- package/esm/ui/Field.svelte +189 -136
- package/esm/ui/Field.svelte.d.ts +13 -6
- package/esm/ui/FieldGroup.svelte +74 -53
- package/esm/ui/FieldGroup.svelte.d.ts +17 -6
- package/esm/ui/Grid.svelte +110 -86
- package/esm/ui/Grid.svelte.d.ts +17 -6
- package/esm/ui/GridLoading.svelte +10 -5
- package/esm/ui/GridLoading.svelte.d.ts +19 -17
- package/esm/ui/GridPaginate.svelte +30 -23
- package/esm/ui/GridPaginate.svelte.d.ts +21 -19
- package/esm/ui/Icon.svelte +67 -32
- package/esm/ui/Icon.svelte.d.ts +52 -43
- package/esm/ui/Loading.svelte +5 -3
- package/esm/ui/Loading.svelte.d.ts +29 -18
- package/esm/ui/Tooltip.svelte +22 -19
- package/esm/ui/Tooltip.svelte.d.ts +30 -20
- package/esm/ui/dialog/DialogForm.svelte +48 -41
- package/esm/ui/dialog/DialogForm.svelte.d.ts +18 -16
- package/esm/ui/dialog/DialogManagement.svelte.d.ts +22 -21
- package/esm/ui/dialog/DialogPrimitive.svelte +32 -26
- package/esm/ui/dialog/DialogPrimitive.svelte.d.ts +35 -25
- package/esm/ui/dialog/FormEditAction.svelte +20 -12
- package/esm/ui/dialog/FormEditAction.svelte.d.ts +13 -6
- package/esm/ui/dialog/dialog.d.ts +1 -1
- package/esm/ui/internals/FieldContainer.svelte +13 -6
- package/esm/ui/internals/FieldContainer.svelte.d.ts +37 -28
- package/esm/ui/internals/Input.svelte +110 -76
- package/esm/ui/internals/Input.svelte.d.ts +34 -32
- package/esm/ui/internals/Textarea.svelte +39 -31
- package/esm/ui/internals/Textarea.svelte.d.ts +31 -28
- package/esm/ui/internals/select/MultiSelectMelt.svelte +174 -126
- package/esm/ui/internals/select/MultiSelectMelt.svelte.d.ts +29 -27
- package/esm/ui/internals/select/SelectMelt.svelte +168 -133
- package/esm/ui/internals/select/SelectMelt.svelte.d.ts +34 -32
- package/esm/ui/internals/select/SelectRadio.svelte +17 -11
- package/esm/ui/internals/select/SelectRadio.svelte.d.ts +24 -22
- package/esm/ui/link/Link.svelte +11 -6
- package/esm/ui/link/Link.svelte.d.ts +31 -22
- package/esm/ui/link/LinkPlus.svelte +19 -16
- package/esm/ui/link/LinkPlus.svelte.d.ts +20 -18
- package/esm/vite/index.d.ts +2 -3
- package/esm/vite/index.js +33 -26
- package/package.json +14 -14
- package/esm/auth/static/assets/Page-BUfjaN-D.d.ts +0 -5
- package/esm/auth/static/assets/Page-BUfjaN-D.js +0 -19
- package/esm/auth/static/assets/Page-CJ58H1vl.css +0 -1
- package/esm/auth/static/assets/Page-CaDAqmBS.d.ts +0 -5
- package/esm/auth/static/assets/Page-CaDAqmBS.js +0 -1
- package/esm/auth/static/assets/Page-DhdZddzJ.d.ts +0 -5
- package/esm/auth/static/assets/Page-DhdZddzJ.js +0 -1
- package/esm/auth/static/assets/index-D-Ztdt2o.d.ts +0 -54
- package/esm/auth/static/assets/index-D-Ztdt2o.js +0 -2
- /package/esm/auth/static/assets/{index-BDy4A_14.css → index-DKWpA6v7.css} +0 -0
- /package/esm/{api → server}/index.js +0 -0
|
@@ -1,20 +1,31 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
1
|
+
interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
|
|
2
|
+
new (options: import('svelte').ComponentConstructorOptions<Props>): import('svelte').SvelteComponent<Props, Events, Slots> & {
|
|
3
|
+
$$bindings?: Bindings;
|
|
4
|
+
} & Exports;
|
|
5
|
+
(internal: unknown, props: Props & {
|
|
6
|
+
$$events?: Events;
|
|
7
|
+
$$slots?: Slots;
|
|
8
|
+
}): Exports & {
|
|
9
|
+
$set?: any;
|
|
10
|
+
$on?: any;
|
|
5
11
|
};
|
|
6
|
-
|
|
7
|
-
[evt: string]: CustomEvent<any>;
|
|
8
|
-
};
|
|
9
|
-
slots: {
|
|
10
|
-
default: {};
|
|
11
|
-
};
|
|
12
|
-
exports?: {} | undefined;
|
|
13
|
-
bindings?: string | undefined;
|
|
14
|
-
};
|
|
15
|
-
export type LoadingProps = typeof __propDef.props;
|
|
16
|
-
export type LoadingEvents = typeof __propDef.events;
|
|
17
|
-
export type LoadingSlots = typeof __propDef.slots;
|
|
18
|
-
export default class Loading extends SvelteComponent<LoadingProps, LoadingEvents, LoadingSlots> {
|
|
12
|
+
z_$$bindings?: Bindings;
|
|
19
13
|
}
|
|
20
|
-
|
|
14
|
+
type $$__sveltets_2_PropsWithChildren<Props, Slots> = Props & (Slots extends {
|
|
15
|
+
default: any;
|
|
16
|
+
} ? Props extends Record<string, never> ? any : {
|
|
17
|
+
children?: any;
|
|
18
|
+
} : {});
|
|
19
|
+
declare const Loading: $$__sveltets_2_IsomorphicComponent<$$__sveltets_2_PropsWithChildren<{
|
|
20
|
+
class?: string;
|
|
21
|
+
}, {
|
|
22
|
+
default: {};
|
|
23
|
+
}>, {
|
|
24
|
+
[evt: string]: CustomEvent<any>;
|
|
25
|
+
}, {
|
|
26
|
+
default: {};
|
|
27
|
+
}, {
|
|
28
|
+
class: string;
|
|
29
|
+
}, string>;
|
|
30
|
+
type Loading = InstanceType<typeof Loading>;
|
|
31
|
+
export default Loading;
|
package/esm/ui/Tooltip.svelte
CHANGED
|
@@ -1,22 +1,25 @@
|
|
|
1
|
-
<script
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { createTooltip } from '@melt-ui/svelte'
|
|
3
|
+
import { fade } from 'svelte/transition'
|
|
4
|
+
|
|
5
|
+
export let text = ''
|
|
6
|
+
export let hideTooltip = false
|
|
7
|
+
|
|
8
|
+
const {
|
|
9
|
+
elements: { trigger, content, arrow },
|
|
10
|
+
states: { open },
|
|
11
|
+
} = createTooltip({
|
|
12
|
+
positioning: {
|
|
13
|
+
placement: 'top',
|
|
14
|
+
},
|
|
15
|
+
openDelay: 0,
|
|
16
|
+
closeDelay: 0,
|
|
17
|
+
closeOnPointerDown: false,
|
|
18
|
+
forceVisible: true,
|
|
19
|
+
escapeBehavior: 'close',
|
|
20
|
+
group: true,
|
|
21
|
+
// disableHoverableContent: true,
|
|
22
|
+
})
|
|
20
23
|
</script>
|
|
21
24
|
|
|
22
25
|
<button type="button" class="trigger" {...$trigger} use:trigger aria-label="Add">
|
|
@@ -1,22 +1,32 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
|
|
2
|
+
new (options: import('svelte').ComponentConstructorOptions<Props>): import('svelte').SvelteComponent<Props, Events, Slots> & {
|
|
3
|
+
$$bindings?: Bindings;
|
|
4
|
+
} & Exports;
|
|
5
|
+
(internal: unknown, props: Props & {
|
|
6
|
+
$$events?: Events;
|
|
7
|
+
$$slots?: Slots;
|
|
8
|
+
}): Exports & {
|
|
9
|
+
$set?: any;
|
|
10
|
+
$on?: any;
|
|
6
11
|
};
|
|
7
|
-
|
|
8
|
-
[evt: string]: CustomEvent<any>;
|
|
9
|
-
};
|
|
10
|
-
slots: {
|
|
11
|
-
default: {};
|
|
12
|
-
tooltip: {};
|
|
13
|
-
};
|
|
14
|
-
exports?: {} | undefined;
|
|
15
|
-
bindings?: string | undefined;
|
|
16
|
-
};
|
|
17
|
-
export type TooltipProps = typeof __propDef.props;
|
|
18
|
-
export type TooltipEvents = typeof __propDef.events;
|
|
19
|
-
export type TooltipSlots = typeof __propDef.slots;
|
|
20
|
-
export default class Tooltip extends SvelteComponent<TooltipProps, TooltipEvents, TooltipSlots> {
|
|
12
|
+
z_$$bindings?: Bindings;
|
|
21
13
|
}
|
|
22
|
-
|
|
14
|
+
type $$__sveltets_2_PropsWithChildren<Props, Slots> = Props & (Slots extends {
|
|
15
|
+
default: any;
|
|
16
|
+
} ? Props extends Record<string, never> ? any : {
|
|
17
|
+
children?: any;
|
|
18
|
+
} : {});
|
|
19
|
+
declare const Tooltip: $$__sveltets_2_IsomorphicComponent<$$__sveltets_2_PropsWithChildren<{
|
|
20
|
+
text?: string;
|
|
21
|
+
hideTooltip?: boolean;
|
|
22
|
+
}, {
|
|
23
|
+
default: {};
|
|
24
|
+
tooltip: {};
|
|
25
|
+
}>, {
|
|
26
|
+
[evt: string]: CustomEvent<any>;
|
|
27
|
+
}, {
|
|
28
|
+
default: {};
|
|
29
|
+
tooltip: {};
|
|
30
|
+
}, {}, string>;
|
|
31
|
+
type Tooltip = InstanceType<typeof Tooltip>;
|
|
32
|
+
export default Tooltip;
|
|
@@ -1,44 +1,51 @@
|
|
|
1
|
-
<script
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { FieldGroup, storeItem } from '../..'
|
|
3
|
+
import { cellsBuildor } from '../../cellsBuildor'
|
|
4
|
+
import { dialog, type DialogMetaDataInternal } from './dialog'
|
|
5
|
+
import DialogPrimitive from './DialogPrimitive.svelte'
|
|
6
|
+
import FormEditAction from './FormEditAction.svelte'
|
|
7
|
+
|
|
8
|
+
export let toShow: DialogMetaDataInternal
|
|
9
|
+
|
|
10
|
+
$: cells = cellsBuildor(toShow.repo!, toShow.cells!)
|
|
11
|
+
$: store = toShow.store ?? storeItem(toShow.repo!)
|
|
12
|
+
|
|
13
|
+
$: {
|
|
14
|
+
if (toShow.type === 'update' || toShow.type === 'view') {
|
|
15
|
+
store.set({ item: toShow.defaults, errors: {}, loading: false, globalError: undefined })
|
|
16
|
+
} else {
|
|
17
|
+
store.create(toShow.defaults ?? {})
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
const onCreate = (e: CustomEvent) => {
|
|
22
|
+
dialog.close(toShow.id, { success: true, item: e.detail })
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
let isLoading = false
|
|
26
|
+
const onInsert = async () => {
|
|
27
|
+
isLoading = true
|
|
28
|
+
try {
|
|
29
|
+
const result = await store.save()
|
|
30
|
+
if (result) {
|
|
31
|
+
dialog.close(toShow.id, { success: true, item: result })
|
|
32
|
+
}
|
|
33
|
+
} catch (e) {
|
|
34
|
+
if (toShow.reThrow) {
|
|
35
|
+
throw e
|
|
36
|
+
}
|
|
37
|
+
} finally {
|
|
38
|
+
isLoading = false
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
const onDelete = async () => {
|
|
43
|
+
const res = await dialog.confirmDelete('')
|
|
44
|
+
if (res.success) {
|
|
45
|
+
await store.delete()
|
|
46
|
+
dialog.close(toShow.id, { success: true, item: $store.item })
|
|
47
|
+
}
|
|
48
|
+
}
|
|
42
49
|
</script>
|
|
43
50
|
|
|
44
51
|
<DialogPrimitive
|
|
@@ -1,19 +1,21 @@
|
|
|
1
|
-
import { SvelteComponent } from "svelte";
|
|
2
1
|
import { type DialogMetaDataInternal } from './dialog';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
2
|
+
interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
|
|
3
|
+
new (options: import('svelte').ComponentConstructorOptions<Props>): import('svelte').SvelteComponent<Props, Events, Slots> & {
|
|
4
|
+
$$bindings?: Bindings;
|
|
5
|
+
} & Exports;
|
|
6
|
+
(internal: unknown, props: Props & {
|
|
7
|
+
$$events?: Events;
|
|
8
|
+
$$slots?: Slots;
|
|
9
|
+
}): Exports & {
|
|
10
|
+
$set?: any;
|
|
11
|
+
$on?: any;
|
|
6
12
|
};
|
|
7
|
-
|
|
8
|
-
[evt: string]: CustomEvent<any>;
|
|
9
|
-
};
|
|
10
|
-
slots: {};
|
|
11
|
-
exports?: {} | undefined;
|
|
12
|
-
bindings?: string | undefined;
|
|
13
|
-
};
|
|
14
|
-
export type DialogFormProps = typeof __propDef.props;
|
|
15
|
-
export type DialogFormEvents = typeof __propDef.events;
|
|
16
|
-
export type DialogFormSlots = typeof __propDef.slots;
|
|
17
|
-
export default class DialogForm extends SvelteComponent<DialogFormProps, DialogFormEvents, DialogFormSlots> {
|
|
13
|
+
z_$$bindings?: Bindings;
|
|
18
14
|
}
|
|
19
|
-
|
|
15
|
+
declare const DialogForm: $$__sveltets_2_IsomorphicComponent<{
|
|
16
|
+
toShow: DialogMetaDataInternal;
|
|
17
|
+
}, {
|
|
18
|
+
[evt: string]: CustomEvent<any>;
|
|
19
|
+
}, {}, {}, string>;
|
|
20
|
+
type DialogForm = InstanceType<typeof DialogForm>;
|
|
21
|
+
export default DialogForm;
|
|
@@ -1,25 +1,26 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
/** @typedef {typeof __propDef.slots} DialogManagementSlots */
|
|
4
|
-
export default class DialogManagement extends SvelteComponent<{
|
|
1
|
+
export default DialogManagement;
|
|
2
|
+
type DialogManagement = SvelteComponent<{
|
|
5
3
|
[x: string]: never;
|
|
6
4
|
}, {
|
|
7
5
|
[evt: string]: CustomEvent<any>;
|
|
8
|
-
}, {}> {
|
|
9
|
-
|
|
10
|
-
export type DialogManagementProps = typeof __propDef.props;
|
|
11
|
-
export type DialogManagementEvents = typeof __propDef.events;
|
|
12
|
-
export type DialogManagementSlots = typeof __propDef.slots;
|
|
13
|
-
import { SvelteComponent } from "svelte";
|
|
14
|
-
declare const __propDef: {
|
|
15
|
-
props: {
|
|
16
|
-
[x: string]: never;
|
|
17
|
-
};
|
|
18
|
-
events: {
|
|
19
|
-
[evt: string]: CustomEvent<any>;
|
|
20
|
-
};
|
|
21
|
-
slots: {};
|
|
22
|
-
exports?: undefined;
|
|
23
|
-
bindings?: undefined;
|
|
6
|
+
}, {}> & {
|
|
7
|
+
$$bindings?: string | undefined;
|
|
24
8
|
};
|
|
25
|
-
|
|
9
|
+
declare const DialogManagement: $$__sveltets_2_IsomorphicComponent<{
|
|
10
|
+
[x: string]: never;
|
|
11
|
+
}, {
|
|
12
|
+
[evt: string]: CustomEvent<any>;
|
|
13
|
+
}, {}, {}, string>;
|
|
14
|
+
interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
|
|
15
|
+
new (options: import("svelte").ComponentConstructorOptions<Props>): import("svelte").SvelteComponent<Props, Events, Slots> & {
|
|
16
|
+
$$bindings?: Bindings;
|
|
17
|
+
} & Exports;
|
|
18
|
+
(internal: unknown, props: {
|
|
19
|
+
$$events?: Events;
|
|
20
|
+
$$slots?: Slots;
|
|
21
|
+
}): Exports & {
|
|
22
|
+
$set?: any;
|
|
23
|
+
$on?: any;
|
|
24
|
+
};
|
|
25
|
+
z_$$bindings?: Bindings;
|
|
26
|
+
}
|
|
@@ -1,29 +1,35 @@
|
|
|
1
|
-
<script
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
}
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { createDialog } from '@melt-ui/svelte'
|
|
3
|
+
import { createEventDispatcher } from 'svelte'
|
|
4
|
+
import { fade } from 'svelte/transition'
|
|
5
|
+
|
|
6
|
+
import { LibIcon_Cross, tw, type BaseItemLight } from '../../'
|
|
7
|
+
import { flyAndScale } from '../../utils/transition'
|
|
8
|
+
import Icon from '../Icon.svelte'
|
|
9
|
+
import LinkPlus from '../link/LinkPlus.svelte'
|
|
10
|
+
|
|
11
|
+
export let detail: BaseItemLight | undefined = undefined
|
|
12
|
+
export let open: boolean = false
|
|
13
|
+
export let classes: { root?: string } = {}
|
|
14
|
+
|
|
15
|
+
const {
|
|
16
|
+
elements: { trigger, overlay, content, title: localTitle, description, close, portalled },
|
|
17
|
+
states: { open: localOpen },
|
|
18
|
+
} = createDialog({
|
|
19
|
+
forceVisible: true,
|
|
20
|
+
defaultOpen: open,
|
|
21
|
+
closeOnOutsideClick: false,
|
|
22
|
+
onOpenChange: (open) => {
|
|
23
|
+
dispatchChange('yop there')
|
|
24
|
+
return open.next
|
|
25
|
+
},
|
|
26
|
+
})
|
|
27
|
+
|
|
28
|
+
const dispatch = createEventDispatcher()
|
|
29
|
+
|
|
30
|
+
function dispatchChange(_data: any) {
|
|
31
|
+
dispatch('change', _data)
|
|
32
|
+
}
|
|
27
33
|
</script>
|
|
28
34
|
|
|
29
35
|
<div
|
|
@@ -1,28 +1,38 @@
|
|
|
1
|
-
import { SvelteComponent } from "svelte";
|
|
2
1
|
import { type BaseItemLight } from '../../';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
2
|
+
interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
|
|
3
|
+
new (options: import('svelte').ComponentConstructorOptions<Props>): import('svelte').SvelteComponent<Props, Events, Slots> & {
|
|
4
|
+
$$bindings?: Bindings;
|
|
5
|
+
} & Exports;
|
|
6
|
+
(internal: unknown, props: Props & {
|
|
7
|
+
$$events?: Events;
|
|
8
|
+
$$slots?: Slots;
|
|
9
|
+
}): Exports & {
|
|
10
|
+
$set?: any;
|
|
11
|
+
$on?: any;
|
|
10
12
|
};
|
|
11
|
-
|
|
12
|
-
change: CustomEvent<any>;
|
|
13
|
-
} & {
|
|
14
|
-
[evt: string]: CustomEvent<any>;
|
|
15
|
-
};
|
|
16
|
-
slots: {
|
|
17
|
-
default: {};
|
|
18
|
-
actions: {};
|
|
19
|
-
};
|
|
20
|
-
exports?: {} | undefined;
|
|
21
|
-
bindings?: string | undefined;
|
|
22
|
-
};
|
|
23
|
-
export type DialogPrimitiveProps = typeof __propDef.props;
|
|
24
|
-
export type DialogPrimitiveEvents = typeof __propDef.events;
|
|
25
|
-
export type DialogPrimitiveSlots = typeof __propDef.slots;
|
|
26
|
-
export default class DialogPrimitive extends SvelteComponent<DialogPrimitiveProps, DialogPrimitiveEvents, DialogPrimitiveSlots> {
|
|
13
|
+
z_$$bindings?: Bindings;
|
|
27
14
|
}
|
|
28
|
-
|
|
15
|
+
type $$__sveltets_2_PropsWithChildren<Props, Slots> = Props & (Slots extends {
|
|
16
|
+
default: any;
|
|
17
|
+
} ? Props extends Record<string, never> ? any : {
|
|
18
|
+
children?: any;
|
|
19
|
+
} : {});
|
|
20
|
+
declare const DialogPrimitive: $$__sveltets_2_IsomorphicComponent<$$__sveltets_2_PropsWithChildren<{
|
|
21
|
+
detail?: BaseItemLight | undefined;
|
|
22
|
+
open?: boolean;
|
|
23
|
+
classes?: {
|
|
24
|
+
root?: string;
|
|
25
|
+
};
|
|
26
|
+
}, {
|
|
27
|
+
default: {};
|
|
28
|
+
actions: {};
|
|
29
|
+
}>, {
|
|
30
|
+
change: CustomEvent<any>;
|
|
31
|
+
} & {
|
|
32
|
+
[evt: string]: CustomEvent<any>;
|
|
33
|
+
}, {
|
|
34
|
+
default: {};
|
|
35
|
+
actions: {};
|
|
36
|
+
}, {}, string>;
|
|
37
|
+
type DialogPrimitive = InstanceType<typeof DialogPrimitive>;
|
|
38
|
+
export default DialogPrimitive;
|
|
@@ -1,15 +1,23 @@
|
|
|
1
|
-
<script generics="T extends any">
|
|
2
|
-
import
|
|
3
|
-
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
1
|
+
<script lang="ts" generics="T extends any">
|
|
2
|
+
import { createEventDispatcher } from 'svelte'
|
|
3
|
+
|
|
4
|
+
import type { StoreItem } from '../..'
|
|
5
|
+
import Button from '../Button.svelte'
|
|
6
|
+
import Icon from '../Icon.svelte'
|
|
7
|
+
import { LibIcon_Add, LibIcon_Check, LibIcon_Delete } from '../LibIcon'
|
|
8
|
+
import type { DialogType } from './dialog'
|
|
9
|
+
|
|
10
|
+
export let store: StoreItem<T>
|
|
11
|
+
export let type: DialogType
|
|
12
|
+
export let wDelete = false
|
|
13
|
+
|
|
14
|
+
export let textCreate = 'Créer'
|
|
15
|
+
|
|
16
|
+
const dispatch = createEventDispatcher()
|
|
17
|
+
|
|
18
|
+
function dispatchDelete() {
|
|
19
|
+
dispatch('delete')
|
|
20
|
+
}
|
|
13
21
|
</script>
|
|
14
22
|
|
|
15
23
|
<div class="mt-2 flex items-center justify-between">
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { SvelteComponent } from "svelte";
|
|
2
1
|
import type { StoreItem } from '../..';
|
|
3
2
|
import type { DialogType } from './dialog';
|
|
4
3
|
declare class __sveltets_Render<T extends any> {
|
|
@@ -15,10 +14,18 @@ declare class __sveltets_Render<T extends any> {
|
|
|
15
14
|
[evt: string]: CustomEvent<any>;
|
|
16
15
|
};
|
|
17
16
|
slots(): {};
|
|
17
|
+
bindings(): string;
|
|
18
|
+
exports(): {};
|
|
18
19
|
}
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
interface $$IsomorphicComponent {
|
|
21
|
+
new <T extends any>(options: import('svelte').ComponentConstructorOptions<ReturnType<__sveltets_Render<T>['props']>>): import('svelte').SvelteComponent<ReturnType<__sveltets_Render<T>['props']>, ReturnType<__sveltets_Render<T>['events']>, ReturnType<__sveltets_Render<T>['slots']>> & {
|
|
22
|
+
$$bindings?: ReturnType<__sveltets_Render<T>['bindings']>;
|
|
23
|
+
} & ReturnType<__sveltets_Render<T>['exports']>;
|
|
24
|
+
<T extends any>(internal: unknown, props: ReturnType<__sveltets_Render<T>['props']> & {
|
|
25
|
+
$$events?: ReturnType<__sveltets_Render<T>['events']>;
|
|
26
|
+
}): ReturnType<__sveltets_Render<T>['exports']>;
|
|
27
|
+
z_$$bindings?: ReturnType<__sveltets_Render<any>['bindings']>;
|
|
23
28
|
}
|
|
24
|
-
|
|
29
|
+
declare const FormEditAction: $$IsomorphicComponent;
|
|
30
|
+
type FormEditAction<T extends any> = InstanceType<typeof FormEditAction<T>>;
|
|
31
|
+
export default FormEditAction;
|
|
@@ -50,6 +50,6 @@ export declare const dialog: {
|
|
|
50
50
|
show: (dialog: DialogMetaData) => Promise<ResultClose<any>>;
|
|
51
51
|
close: (id: number, result: ResultClose) => void;
|
|
52
52
|
closeAll: () => void;
|
|
53
|
-
subscribe: (this: void, run: import("svelte/store").Subscriber<DialogMetaDataInternal<any>[]>, invalidate?:
|
|
53
|
+
subscribe: (this: void, run: import("svelte/store").Subscriber<DialogMetaDataInternal<any>[]>, invalidate?: () => void) => import("svelte/store").Unsubscriber;
|
|
54
54
|
};
|
|
55
55
|
export {};
|
|
@@ -1,9 +1,16 @@
|
|
|
1
|
-
<script
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
export let
|
|
5
|
-
export let
|
|
6
|
-
export let
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { tw } from '../../utils/tailwind'
|
|
3
|
+
|
|
4
|
+
export let label: string = 'label'
|
|
5
|
+
export let forId: string
|
|
6
|
+
export let required = false
|
|
7
|
+
export let error: string = ''
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* example usage for paginate
|
|
11
|
+
* classes={{ label: 'justify-end' }}
|
|
12
|
+
*/
|
|
13
|
+
export let classes: { label?: string; slot?: string } = {}
|
|
7
14
|
</script>
|
|
8
15
|
|
|
9
16
|
<div class="form-control w-full">
|
|
@@ -1,30 +1,39 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
*/ classes?: {
|
|
12
|
-
label?: string;
|
|
13
|
-
slot?: string;
|
|
14
|
-
};
|
|
15
|
-
};
|
|
16
|
-
events: {
|
|
17
|
-
[evt: string]: CustomEvent<any>;
|
|
18
|
-
};
|
|
19
|
-
slots: {
|
|
20
|
-
default: {};
|
|
1
|
+
interface $$__sveltets_2_IsomorphicComponent<Props extends Record<string, any> = any, Events extends Record<string, any> = any, Slots extends Record<string, any> = any, Exports = {}, Bindings = string> {
|
|
2
|
+
new (options: import('svelte').ComponentConstructorOptions<Props>): import('svelte').SvelteComponent<Props, Events, Slots> & {
|
|
3
|
+
$$bindings?: Bindings;
|
|
4
|
+
} & Exports;
|
|
5
|
+
(internal: unknown, props: Props & {
|
|
6
|
+
$$events?: Events;
|
|
7
|
+
$$slots?: Slots;
|
|
8
|
+
}): Exports & {
|
|
9
|
+
$set?: any;
|
|
10
|
+
$on?: any;
|
|
21
11
|
};
|
|
22
|
-
|
|
23
|
-
bindings?: string | undefined;
|
|
24
|
-
};
|
|
25
|
-
export type FieldContainerProps = typeof __propDef.props;
|
|
26
|
-
export type FieldContainerEvents = typeof __propDef.events;
|
|
27
|
-
export type FieldContainerSlots = typeof __propDef.slots;
|
|
28
|
-
export default class FieldContainer extends SvelteComponent<FieldContainerProps, FieldContainerEvents, FieldContainerSlots> {
|
|
12
|
+
z_$$bindings?: Bindings;
|
|
29
13
|
}
|
|
30
|
-
|
|
14
|
+
type $$__sveltets_2_PropsWithChildren<Props, Slots> = Props & (Slots extends {
|
|
15
|
+
default: any;
|
|
16
|
+
} ? Props extends Record<string, never> ? any : {
|
|
17
|
+
children?: any;
|
|
18
|
+
} : {});
|
|
19
|
+
declare const FieldContainer: $$__sveltets_2_IsomorphicComponent<$$__sveltets_2_PropsWithChildren<{
|
|
20
|
+
label?: string;
|
|
21
|
+
forId: string;
|
|
22
|
+
required?: boolean;
|
|
23
|
+
error?: string;
|
|
24
|
+
/**
|
|
25
|
+
* example usage for paginate
|
|
26
|
+
* classes={{ label: 'justify-end' }}
|
|
27
|
+
*/ classes?: {
|
|
28
|
+
label?: string;
|
|
29
|
+
slot?: string;
|
|
30
|
+
};
|
|
31
|
+
}, {
|
|
32
|
+
default: {};
|
|
33
|
+
}>, {
|
|
34
|
+
[evt: string]: CustomEvent<any>;
|
|
35
|
+
}, {
|
|
36
|
+
default: {};
|
|
37
|
+
}, {}, string>;
|
|
38
|
+
type FieldContainer = InstanceType<typeof FieldContainer>;
|
|
39
|
+
export default FieldContainer;
|