firstly 0.0.12 → 0.0.14
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/api/index.d.ts +9 -0
- package/esm/api/index.js +3 -1
- 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 +99 -34
- package/esm/auth/server/handleGuard.d.ts +16 -0
- package/esm/auth/server/handleGuard.js +67 -0
- package/esm/auth/server/helperFirstly.d.ts +1 -1
- package/esm/auth/server/helperFirstly.js +1 -0
- package/esm/auth/server/index.d.ts +3 -1
- package/esm/auth/server/index.js +3 -1
- package/esm/auth/server/module.d.ts +105 -89
- package/esm/auth/server/module.js +55 -42
- package/esm/auth/server/providers/github.d.ts +4 -2
- package/esm/auth/server/providers/github.js +2 -2
- package/esm/auth/static/assets/Page-B0XXxe0N.d.ts +6 -0
- package/esm/auth/static/assets/Page-B0XXxe0N.js +1 -0
- package/esm/auth/static/assets/Page-DdKMiUZn.d.ts +6 -0
- package/esm/auth/static/assets/Page-DdKMiUZn.js +20 -0
- package/esm/auth/static/assets/Page-UV_hqY7I.d.ts +6 -0
- package/esm/auth/static/assets/Page-UV_hqY7I.js +1 -0
- package/esm/auth/static/assets/Page-mK42zGEw.css +1 -0
- package/esm/auth/static/assets/index-C9jzxOBu.d.ts +151 -0
- package/esm/auth/static/assets/index-C9jzxOBu.js +42 -0
- package/esm/auth/static/assets/index-DKWpA6v7.css +4 -0
- package/esm/auth/static/index.html +11 -11
- package/esm/auth/types.d.ts +26 -3
- package/esm/bin/cmd.js +423 -152
- package/esm/cellsBuildor.js +1 -1
- package/esm/common.d.ts +5 -0
- package/esm/common.js +8 -0
- package/esm/cron/server/index.js +1 -1
- package/esm/feedback/FeedbackController.js +58 -53
- package/esm/feedback/server/index.d.ts +6 -15
- package/esm/feedback/server/index.js +4 -5
- package/esm/feedback/types.d.ts +14 -0
- package/esm/feedback/types.js +4 -0
- package/esm/feedback/ui/DialogIssue.svelte +131 -119
- package/esm/feedback/ui/DialogIssue.svelte.d.ts +20 -18
- package/esm/feedback/ui/DialogIssues.svelte +108 -99
- package/esm/feedback/ui/DialogIssues.svelte.d.ts +20 -18
- package/esm/feedback/ui/DialogMilestones.svelte +40 -34
- 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/index.d.ts +2 -5
- package/esm/index.js +2 -8
- package/esm/mail/server/index.d.ts +9 -2
- package/esm/mail/server/index.js +3 -1
- package/esm/mail/templates/DefaultMail.svelte +81 -61
- package/esm/mail/templates/DefaultMail.svelte.d.ts +28 -26
- package/esm/server/index.d.ts +0 -0
- package/esm/server/index.js +1 -0
- package/esm/storeItem.d.ts +1 -4
- package/esm/storeItem.js +1 -1
- package/esm/storeList.d.ts +1 -4
- package/esm/sveltekit/server/index.d.ts +3 -9
- package/esm/sveltekit/server/index.js +3 -0
- package/esm/ui/Button.svelte +112 -89
- package/esm/ui/Button.svelte.d.ts +34 -24
- package/esm/ui/Clipboardable.svelte +24 -17
- package/esm/ui/Clipboardable.svelte.d.ts +34 -23
- package/esm/ui/Field.svelte +328 -285
- package/esm/ui/Field.svelte.d.ts +15 -8
- package/esm/ui/FieldGroup.svelte +112 -91
- package/esm/ui/FieldGroup.svelte.d.ts +17 -6
- package/esm/ui/Grid.svelte +322 -308
- package/esm/ui/Grid.svelte.d.ts +17 -6
- package/esm/ui/GridLoading.svelte +28 -27
- package/esm/ui/GridLoading.svelte.d.ts +19 -17
- package/esm/ui/GridPaginate.svelte +68 -61
- package/esm/ui/GridPaginate.svelte.d.ts +21 -19
- package/esm/ui/Icon.svelte +116 -80
- package/esm/ui/Icon.svelte.d.ts +52 -43
- package/esm/ui/Loading.svelte +10 -8
- package/esm/ui/Loading.svelte.d.ts +29 -18
- package/esm/ui/Tooltip.svelte +38 -35
- package/esm/ui/Tooltip.svelte.d.ts +30 -20
- package/esm/ui/dialog/DialogForm.svelte +70 -63
- package/esm/ui/dialog/DialogForm.svelte.d.ts +18 -16
- package/esm/ui/dialog/DialogManagement.svelte +74 -74
- package/esm/ui/dialog/DialogManagement.svelte.d.ts +22 -21
- package/esm/ui/dialog/DialogPrimitive.svelte +82 -76
- package/esm/ui/dialog/DialogPrimitive.svelte.d.ts +35 -25
- package/esm/ui/dialog/FormEditAction.svelte +58 -50
- package/esm/ui/dialog/FormEditAction.svelte.d.ts +13 -6
- package/esm/ui/dialog/dialog.d.ts +1 -4
- package/esm/ui/internals/FieldContainer.svelte +24 -17
- package/esm/ui/internals/FieldContainer.svelte.d.ts +37 -28
- package/esm/ui/internals/Input.svelte +136 -102
- package/esm/ui/internals/Input.svelte.d.ts +34 -32
- package/esm/ui/internals/Textarea.svelte +60 -52
- package/esm/ui/internals/Textarea.svelte.d.ts +31 -28
- package/esm/ui/internals/select/MultiSelectMelt.svelte +243 -199
- package/esm/ui/internals/select/MultiSelectMelt.svelte.d.ts +29 -27
- package/esm/ui/internals/select/SelectMelt.svelte +254 -219
- package/esm/ui/internals/select/SelectMelt.svelte.d.ts +34 -32
- package/esm/ui/internals/select/SelectRadio.svelte +39 -33
- package/esm/ui/internals/select/SelectRadio.svelte.d.ts +24 -22
- package/esm/ui/link/Link.svelte +25 -20
- package/esm/ui/link/Link.svelte.d.ts +31 -23
- package/esm/ui/link/LinkPlus.svelte +52 -51
- 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 +16 -20
- package/esm/auth/static/assets/Page-Bb8bFlrP.d.ts +0 -4
- package/esm/auth/static/assets/Page-Bb8bFlrP.js +0 -1
- package/esm/auth/static/assets/Page-BxomFlZ8.d.ts +0 -4
- package/esm/auth/static/assets/Page-BxomFlZ8.js +0 -1
- package/esm/auth/static/assets/Page-CaIYu0-y.d.ts +0 -6
- package/esm/auth/static/assets/Page-CaIYu0-y.js +0 -19
- package/esm/auth/static/assets/Page-MkYglNtu.css +0 -1
- package/esm/auth/static/assets/index-Bl0Bk5u0.d.ts +0 -64
- package/esm/auth/static/assets/index-Bl0Bk5u0.js +0 -2
- package/esm/auth/static/assets/index-R27C_TlP.css +0 -4
|
@@ -1,105 +1,114 @@
|
|
|
1
|
-
<script
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
let
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { onMount } from 'svelte'
|
|
3
|
+
|
|
4
|
+
import { FeedbackController } from '..'
|
|
5
|
+
import {
|
|
6
|
+
Button,
|
|
7
|
+
dialog,
|
|
8
|
+
Icon,
|
|
9
|
+
LibIcon_Add,
|
|
10
|
+
LibIcon_Check,
|
|
11
|
+
LibIcon_Search,
|
|
12
|
+
Loading,
|
|
13
|
+
type ResolvedType,
|
|
14
|
+
} from '../..'
|
|
15
|
+
import DialogIssue from './DialogIssue.svelte'
|
|
16
|
+
|
|
17
|
+
export let dialogId: number
|
|
18
|
+
const rmvWarning = dialogId
|
|
19
|
+
|
|
20
|
+
export let milestoneNumber: number
|
|
21
|
+
export let milestoneId: string
|
|
22
|
+
|
|
23
|
+
let state: 'loading' | 'done' = 'loading'
|
|
24
|
+
let issueState: 'OPEN' | 'CLOSED' = 'OPEN'
|
|
25
|
+
|
|
26
|
+
let issues: ResolvedType<ReturnType<typeof FeedbackController.getIssues>> = []
|
|
27
|
+
|
|
28
|
+
const update = async (_issueState: 'OPEN' | 'CLOSED') => {
|
|
29
|
+
issueState = _issueState
|
|
30
|
+
state = 'loading'
|
|
31
|
+
issues = await FeedbackController.getIssues(milestoneNumber, issueState)
|
|
32
|
+
state = 'done'
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
onMount(async () => {
|
|
36
|
+
await update(issueState)
|
|
37
|
+
})
|
|
29
38
|
</script>
|
|
30
39
|
|
|
31
40
|
<div class="mb-4 grid gap-4">
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
41
|
+
<div class="flex justify-between">
|
|
42
|
+
<div>
|
|
43
|
+
<Button
|
|
44
|
+
class={issueState === 'OPEN' ? 'btn-primary' : 'btn-ghost'}
|
|
45
|
+
on:click={() => update('OPEN')}>En cours</Button
|
|
46
|
+
>
|
|
47
|
+
<Button
|
|
48
|
+
class={issueState === 'CLOSED' ? 'btn-primary' : 'btn-ghost'}
|
|
49
|
+
on:click={() => update('CLOSED')}>Clos</Button
|
|
50
|
+
>
|
|
51
|
+
</div>
|
|
43
52
|
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
53
|
+
<Button
|
|
54
|
+
on:click={async () => {
|
|
55
|
+
await dialog.show({
|
|
56
|
+
component: DialogIssue,
|
|
57
|
+
classes: { root: 'overflow-auto w-[80vh] h-[80vh]' },
|
|
58
|
+
props: { issueNumber: null, milestoneId },
|
|
59
|
+
detail: {
|
|
60
|
+
caption: 'Nouveau Feedback',
|
|
61
|
+
icon: { data: LibIcon_Search },
|
|
62
|
+
},
|
|
63
|
+
})
|
|
64
|
+
await update(issueState)
|
|
65
|
+
}}
|
|
66
|
+
>
|
|
67
|
+
<Icon data={LibIcon_Add}></Icon>
|
|
68
|
+
</Button>
|
|
69
|
+
</div>
|
|
61
70
|
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
71
|
+
{#each issues as issue}
|
|
72
|
+
<Button
|
|
73
|
+
on:click={async () => {
|
|
74
|
+
await dialog.show({
|
|
75
|
+
component: DialogIssue,
|
|
76
|
+
classes: { root: 'overflow-auto w-[80vh] h-[80vh]' },
|
|
77
|
+
props: { issueNumber: issue.number, milestoneId },
|
|
78
|
+
detail: {
|
|
79
|
+
caption: '#' + issue.number + ' - ' + issue.titleHTML,
|
|
80
|
+
icon: { data: issue.state === 'OPEN' ? LibIcon_Search : LibIcon_Check },
|
|
81
|
+
},
|
|
82
|
+
})
|
|
83
|
+
await update(issueState)
|
|
84
|
+
}}
|
|
85
|
+
class="btn-neutral"
|
|
86
|
+
>
|
|
87
|
+
<div class="flex w-full justify-center justify-items-center text-left">
|
|
88
|
+
<div class="flex-grow">
|
|
89
|
+
<span class="text-base-content/60 mr-2 inline-block w-8 text-right text-xs italic"
|
|
90
|
+
>#{issue.number}</span
|
|
91
|
+
>
|
|
92
|
+
{@html issue.titleHTML}
|
|
93
|
+
</div>
|
|
94
|
+
{#if issue.highlight}
|
|
95
|
+
<span class="badge badge-warning">En attente de réponse</span>
|
|
96
|
+
{/if}
|
|
97
|
+
</div>
|
|
98
|
+
</Button>
|
|
99
|
+
{:else}
|
|
100
|
+
{#if state === 'loading'}
|
|
101
|
+
<Loading class="h-12"></Loading>
|
|
102
|
+
<Loading class="h-12"></Loading>
|
|
103
|
+
<Loading class="h-12"></Loading>
|
|
104
|
+
{:else}
|
|
105
|
+
<div class="flex flex-col items-center justify-center p-8 text-center text-gray-500">
|
|
106
|
+
<div class="mb-4">
|
|
107
|
+
<Icon data={LibIcon_Search} size="4rem"></Icon>
|
|
108
|
+
</div>
|
|
109
|
+
<p class="text-lg font-medium">Aucun feedback <b>{issueState}</b> pour le moment</p>
|
|
110
|
+
<p class="mt-2 text-sm">Soyez le premier à donner votre avis sur cette version !</p>
|
|
111
|
+
</div>
|
|
112
|
+
{/if}
|
|
113
|
+
{/each}
|
|
105
114
|
</div>
|
|
@@ -1,20 +1,22 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
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;
|
|
7
11
|
};
|
|
8
|
-
|
|
9
|
-
[evt: string]: CustomEvent<any>;
|
|
10
|
-
};
|
|
11
|
-
slots: {};
|
|
12
|
-
exports?: {} | undefined;
|
|
13
|
-
bindings?: string | undefined;
|
|
14
|
-
};
|
|
15
|
-
export type DialogIssuesProps = typeof __propDef.props;
|
|
16
|
-
export type DialogIssuesEvents = typeof __propDef.events;
|
|
17
|
-
export type DialogIssuesSlots = typeof __propDef.slots;
|
|
18
|
-
export default class DialogIssues extends SvelteComponent<DialogIssuesProps, DialogIssuesEvents, DialogIssuesSlots> {
|
|
12
|
+
z_$$bindings?: Bindings;
|
|
19
13
|
}
|
|
20
|
-
|
|
14
|
+
declare const DialogIssues: $$__sveltets_2_IsomorphicComponent<{
|
|
15
|
+
dialogId: number;
|
|
16
|
+
milestoneNumber: number;
|
|
17
|
+
milestoneId: string;
|
|
18
|
+
}, {
|
|
19
|
+
[evt: string]: CustomEvent<any>;
|
|
20
|
+
}, {}, {}, string>;
|
|
21
|
+
type DialogIssues = InstanceType<typeof DialogIssues>;
|
|
22
|
+
export default DialogIssues;
|
|
@@ -1,38 +1,44 @@
|
|
|
1
|
-
<script
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
import
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { onMount } from 'svelte'
|
|
3
|
+
|
|
4
|
+
import { FeedbackController } from '..'
|
|
5
|
+
import type { ResolvedType } from '../..'
|
|
6
|
+
import { Button, dialog, Loading } from '../..'
|
|
7
|
+
import DialogIssues from './DialogIssues.svelte'
|
|
8
|
+
|
|
9
|
+
export let dialogId: number
|
|
10
|
+
const rmvWarning = dialogId
|
|
11
|
+
|
|
12
|
+
let state: 'loading' | 'done' = 'loading'
|
|
13
|
+
|
|
14
|
+
let milestones: ResolvedType<ReturnType<typeof FeedbackController.getMilestones>> = []
|
|
15
|
+
onMount(async () => {
|
|
16
|
+
milestones = await FeedbackController.getMilestones()
|
|
17
|
+
state = 'done'
|
|
18
|
+
})
|
|
13
19
|
</script>
|
|
14
20
|
|
|
15
21
|
<div class="mb-4 grid gap-4">
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
22
|
+
{#each milestones as milestone}
|
|
23
|
+
<Button
|
|
24
|
+
on:click={() =>
|
|
25
|
+
dialog.show({
|
|
26
|
+
component: DialogIssues,
|
|
27
|
+
classes: { root: 'overflow-auto w-[85vh] h-[85vh]' },
|
|
28
|
+
props: { milestoneNumber: milestone.number, milestoneId: milestone.id },
|
|
29
|
+
detail: { caption: milestone.title },
|
|
30
|
+
})}
|
|
31
|
+
class="btn-neutral"
|
|
32
|
+
>
|
|
33
|
+
{milestone.title}
|
|
34
|
+
</Button>
|
|
35
|
+
{:else}
|
|
36
|
+
{#if state === 'loading'}
|
|
37
|
+
<Loading class="h-12"></Loading>
|
|
38
|
+
<Loading class="h-12"></Loading>
|
|
39
|
+
<Loading class="h-12"></Loading>
|
|
40
|
+
{:else}
|
|
41
|
+
<p>No milestones found / Filter too strict!</p>
|
|
42
|
+
{/if}
|
|
43
|
+
{/each}
|
|
38
44
|
</div>
|
|
@@ -1,18 +1,20 @@
|
|
|
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
|
-
exports?: {} | undefined;
|
|
11
|
-
bindings?: string | undefined;
|
|
12
|
-
};
|
|
13
|
-
export type DialogMilestonesProps = typeof __propDef.props;
|
|
14
|
-
export type DialogMilestonesEvents = typeof __propDef.events;
|
|
15
|
-
export type DialogMilestonesSlots = typeof __propDef.slots;
|
|
16
|
-
export default class DialogMilestones extends SvelteComponent<DialogMilestonesProps, DialogMilestonesEvents, DialogMilestonesSlots> {
|
|
12
|
+
z_$$bindings?: Bindings;
|
|
17
13
|
}
|
|
18
|
-
|
|
14
|
+
declare const DialogMilestones: $$__sveltets_2_IsomorphicComponent<{
|
|
15
|
+
dialogId: number;
|
|
16
|
+
}, {
|
|
17
|
+
[evt: string]: CustomEvent<any>;
|
|
18
|
+
}, {}, {}, string>;
|
|
19
|
+
type DialogMilestones = InstanceType<typeof DialogMilestones>;
|
|
20
|
+
export default DialogMilestones;
|
|
@@ -1,12 +1,14 @@
|
|
|
1
|
-
<script
|
|
2
|
-
import
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
}
|
|
1
|
+
<script lang="ts">
|
|
2
|
+
import { dialog } from '../../'
|
|
3
|
+
import DialogMilestones from './DialogMilestones.svelte'
|
|
4
|
+
|
|
5
|
+
const list = async () => {
|
|
6
|
+
await dialog.show({
|
|
7
|
+
component: DialogMilestones,
|
|
8
|
+
classes: { root: 'overflow-auto w-[90vh] h-[90vh]' },
|
|
9
|
+
detail: { caption: 'Feedback' },
|
|
10
|
+
})
|
|
11
|
+
}
|
|
10
12
|
</script>
|
|
11
13
|
|
|
12
14
|
<button class="text-secondary" on:click={list}>Feedback</button>
|
|
@@ -1,16 +1,18 @@
|
|
|
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: {
|
|
6
|
+
$$events?: Events;
|
|
7
|
+
$$slots?: Slots;
|
|
8
|
+
}): Exports & {
|
|
9
|
+
$set?: any;
|
|
10
|
+
$on?: any;
|
|
6
11
|
};
|
|
7
|
-
|
|
8
|
-
exports?: {} | undefined;
|
|
9
|
-
bindings?: string | undefined;
|
|
10
|
-
};
|
|
11
|
-
export type FeedbackProps = typeof __propDef.props;
|
|
12
|
-
export type FeedbackEvents = typeof __propDef.events;
|
|
13
|
-
export type FeedbackSlots = typeof __propDef.slots;
|
|
14
|
-
export default class Feedback extends SvelteComponent<FeedbackProps, FeedbackEvents, FeedbackSlots> {
|
|
12
|
+
z_$$bindings?: Bindings;
|
|
15
13
|
}
|
|
16
|
-
|
|
14
|
+
declare const Feedback: $$__sveltets_2_IsomorphicComponent<Record<string, never>, {
|
|
15
|
+
[evt: string]: CustomEvent<any>;
|
|
16
|
+
}, {}, {}, string>;
|
|
17
|
+
type Feedback = InstanceType<typeof Feedback>;
|
|
18
|
+
export default Feedback;
|
package/esm/index.d.ts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import type { FindOptionsBase } from 'remult';
|
|
2
|
-
import { Log } from '@kitql/helpers';
|
|
3
2
|
import type { BaseEnum, BaseItem, FF_Icon } from './BaseEnum.js';
|
|
4
3
|
import type { CellsInput as CellsInput_ForExport } from './cellsBuildor.js';
|
|
5
4
|
import type { ColumnDeciderArgs } from './changeLog/index.js';
|
|
@@ -22,10 +21,8 @@ import { default as LinkPlus } from './ui/link/LinkPlus.svelte';
|
|
|
22
21
|
import { default as Loading } from './ui/Loading.svelte';
|
|
23
22
|
import { default as Tooltip } from './ui/Tooltip.svelte';
|
|
24
23
|
export { Field, FormEditAction, Grid, GridPaginate, FieldGroup, Icon, Link, LinkPlus, Loading, Button, Tooltip, DialogManagement, FieldContainer, SelectMelt, Clipboardable, };
|
|
25
|
-
export
|
|
26
|
-
export
|
|
27
|
-
readonly FF_Role_Admin: "FF_Role.Admin";
|
|
28
|
-
};
|
|
24
|
+
export { FF_Role } from './common.js';
|
|
25
|
+
export { ff_Log } from './common.js';
|
|
29
26
|
export type { BaseEnumOptions } from './BaseEnum.js';
|
|
30
27
|
export type { BaseItem };
|
|
31
28
|
export type BaseItemLight = Partial<BaseItem>;
|
package/esm/index.js
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { Log } from '@kitql/helpers';
|
|
2
1
|
import { storeItem } from './storeItem.js';
|
|
3
2
|
import { storeList } from './storeList.js';
|
|
4
3
|
import { default as Button } from './ui/Button.svelte';
|
|
@@ -20,13 +19,8 @@ import { default as Tooltip } from './ui/Tooltip.svelte';
|
|
|
20
19
|
// Svelte Components
|
|
21
20
|
// ******************************
|
|
22
21
|
export { Field, FormEditAction, Grid, GridPaginate, FieldGroup, Icon, Link, LinkPlus, Loading, Button, Tooltip, DialogManagement, FieldContainer, SelectMelt, Clipboardable, };
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
// ******************************
|
|
26
|
-
export const ff_Log = new Log('firstly');
|
|
27
|
-
export const FF_Role = {
|
|
28
|
-
FF_Role_Admin: 'FF_Role.Admin',
|
|
29
|
-
};
|
|
22
|
+
export { FF_Role } from './common.js';
|
|
23
|
+
export { ff_Log } from './common.js';
|
|
30
24
|
// ******************************
|
|
31
25
|
// Helpers
|
|
32
26
|
// ******************************
|
|
@@ -9,7 +9,7 @@ import type StreamTransport from 'nodemailer/lib/stream-transport';
|
|
|
9
9
|
import type { ComponentProps, ComponentType, SvelteComponent } from 'svelte';
|
|
10
10
|
import { Module } from '../../api';
|
|
11
11
|
import { default as DefaultMail } from '../templates/DefaultMail.svelte';
|
|
12
|
-
export type TransportTypes = SMTPTransport |
|
|
12
|
+
export type TransportTypes = SMTPTransport | SMTPPool | SendmailTransport | StreamTransport | JSONTransport | SESTransport | typeNodemailer.Transport<any> | DefaultOptions;
|
|
13
13
|
export type DefaultOptions = SMTPTransport.Options | SMTPPool.Options | SendmailTransport.Options | StreamTransport.Options | JSONTransport.Options | SESTransport.Options | typeNodemailer.TransportOptions;
|
|
14
14
|
export type MailOptions<ComponentTemplateDefault extends SvelteComponent> = {
|
|
15
15
|
from?: Mail.Options['from'];
|
|
@@ -22,7 +22,14 @@ export type MailOptions<ComponentTemplateDefault extends SvelteComponent> = {
|
|
|
22
22
|
apiUrl?: Parameters<typeof typeNodemailer.createTestAccount>[0];
|
|
23
23
|
};
|
|
24
24
|
declare let transporter: ReturnType<typeof typeNodemailer.createTransport>;
|
|
25
|
-
|
|
25
|
+
declare module 'remult' {
|
|
26
|
+
interface RemultContext {
|
|
27
|
+
/** Better checking is it's present or not, that's why it's "?" */
|
|
28
|
+
sendMail?: SendMail;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
export type SendMail = typeof sendMail;
|
|
32
|
+
declare const sendMail: <ComponentTemplateDefault extends SvelteComponent = DefaultMail>(
|
|
26
33
|
/** usefull for logs, it has NO impact on the mail itself */
|
|
27
34
|
topic: string, mailOptions: Parameters<typeof transporter.sendMail>[0] & {
|
|
28
35
|
templateProps?: ComponentProps<ComponentTemplateDefault> | undefined;
|
package/esm/mail/server/index.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import nodemailer from 'nodemailer';
|
|
2
2
|
import { render } from 'svelty-email';
|
|
3
|
+
import { remult } from 'remult';
|
|
3
4
|
import { cyan, green, magenta, red, sleep, white } from '@kitql/helpers';
|
|
4
5
|
import { Module } from '../../api';
|
|
5
6
|
import { default as DefaultMail } from '../templates/DefaultMail.svelte';
|
|
@@ -35,7 +36,7 @@ const initMail = async (o) => {
|
|
|
35
36
|
}
|
|
36
37
|
}
|
|
37
38
|
};
|
|
38
|
-
|
|
39
|
+
const sendMail = async (topic, mailOptions) => {
|
|
39
40
|
// if the transporter is not ready, wait for it! (it can happen only if nothing is set...)
|
|
40
41
|
for (let i = 0; i < 30; i++) {
|
|
41
42
|
if (transporter !== undefined) {
|
|
@@ -83,6 +84,7 @@ const mailModule = new Module({
|
|
|
83
84
|
export const mail = (o) => {
|
|
84
85
|
mailModule.initApi = () => {
|
|
85
86
|
initMail(o);
|
|
87
|
+
remult.context.sendMail = sendMail;
|
|
86
88
|
};
|
|
87
89
|
return mailModule;
|
|
88
90
|
};
|