firstly 0.0.12 → 0.0.13

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.
Files changed (83) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/esm/api/index.d.ts +1 -0
  3. package/esm/api/index.js +3 -1
  4. package/esm/auth/server/AuthController.server.d.ts +1 -1
  5. package/esm/auth/server/AuthController.server.js +19 -19
  6. package/esm/auth/server/handleGuard.d.ts +16 -0
  7. package/esm/auth/server/handleGuard.js +67 -0
  8. package/esm/auth/server/index.d.ts +3 -1
  9. package/esm/auth/server/index.js +3 -1
  10. package/esm/auth/server/module.d.ts +102 -83
  11. package/esm/auth/server/module.js +55 -42
  12. package/esm/auth/server/providers/github.d.ts +2 -1
  13. package/esm/auth/server/providers/github.js +1 -1
  14. package/esm/auth/static/assets/Page-BUfjaN-D.d.ts +5 -0
  15. package/esm/auth/static/assets/Page-BUfjaN-D.js +19 -0
  16. package/esm/auth/static/assets/Page-CJ58H1vl.css +1 -0
  17. package/esm/auth/static/assets/Page-CaDAqmBS.d.ts +5 -0
  18. package/esm/auth/static/assets/Page-CaDAqmBS.js +1 -0
  19. package/esm/auth/static/assets/Page-DhdZddzJ.d.ts +5 -0
  20. package/esm/auth/static/assets/Page-DhdZddzJ.js +1 -0
  21. package/esm/auth/static/assets/index-BDy4A_14.css +4 -0
  22. package/esm/auth/static/assets/index-D-Ztdt2o.d.ts +54 -0
  23. package/esm/auth/static/assets/index-D-Ztdt2o.js +2 -0
  24. package/esm/auth/static/index.html +11 -11
  25. package/esm/bin/cmd.js +119 -48
  26. package/esm/cellsBuildor.js +1 -1
  27. package/esm/common.d.ts +5 -0
  28. package/esm/common.js +8 -0
  29. package/esm/cron/server/index.js +1 -1
  30. package/esm/feedback/FeedbackController.js +1 -2
  31. package/esm/feedback/ui/DialogIssue.svelte +52 -56
  32. package/esm/feedback/ui/DialogIssues.svelte +71 -71
  33. package/esm/feedback/ui/DialogMilestones.svelte +22 -22
  34. package/esm/index.d.ts +2 -5
  35. package/esm/index.js +2 -8
  36. package/esm/mail/templates/DefaultMail.svelte +17 -17
  37. package/esm/storeItem.d.ts +1 -4
  38. package/esm/storeItem.js +1 -1
  39. package/esm/storeList.d.ts +1 -4
  40. package/esm/sveltekit/server/index.d.ts +3 -0
  41. package/esm/sveltekit/server/index.js +3 -0
  42. package/esm/ui/Button.svelte +33 -33
  43. package/esm/ui/Button.svelte.d.ts +2 -2
  44. package/esm/ui/Clipboardable.svelte +6 -6
  45. package/esm/ui/Clipboardable.svelte.d.ts +4 -4
  46. package/esm/ui/Field.svelte +139 -149
  47. package/esm/ui/Field.svelte.d.ts +2 -2
  48. package/esm/ui/FieldGroup.svelte +38 -38
  49. package/esm/ui/Grid.svelte +212 -222
  50. package/esm/ui/GridLoading.svelte +18 -22
  51. package/esm/ui/GridPaginate.svelte +38 -38
  52. package/esm/ui/Icon.svelte +50 -49
  53. package/esm/ui/Icon.svelte.d.ts +18 -18
  54. package/esm/ui/Loading.svelte +5 -5
  55. package/esm/ui/Tooltip.svelte +16 -16
  56. package/esm/ui/dialog/DialogForm.svelte +22 -22
  57. package/esm/ui/dialog/DialogManagement.svelte +74 -74
  58. package/esm/ui/dialog/DialogPrimitive.svelte +50 -50
  59. package/esm/ui/dialog/FormEditAction.svelte +34 -34
  60. package/esm/ui/dialog/dialog.d.ts +1 -4
  61. package/esm/ui/internals/FieldContainer.svelte +11 -11
  62. package/esm/ui/internals/FieldContainer.svelte.d.ts +3 -3
  63. package/esm/ui/internals/Input.svelte +25 -25
  64. package/esm/ui/internals/Input.svelte.d.ts +1 -1
  65. package/esm/ui/internals/Textarea.svelte +21 -21
  66. package/esm/ui/internals/Textarea.svelte.d.ts +2 -2
  67. package/esm/ui/internals/select/MultiSelectMelt.svelte +69 -73
  68. package/esm/ui/internals/select/SelectMelt.svelte +86 -86
  69. package/esm/ui/internals/select/SelectRadio.svelte +22 -22
  70. package/esm/ui/link/Link.svelte +14 -14
  71. package/esm/ui/link/Link.svelte.d.ts +3 -4
  72. package/esm/ui/link/LinkPlus.svelte +33 -35
  73. package/package.json +14 -18
  74. package/esm/auth/static/assets/Page-Bb8bFlrP.d.ts +0 -4
  75. package/esm/auth/static/assets/Page-Bb8bFlrP.js +0 -1
  76. package/esm/auth/static/assets/Page-BxomFlZ8.d.ts +0 -4
  77. package/esm/auth/static/assets/Page-BxomFlZ8.js +0 -1
  78. package/esm/auth/static/assets/Page-CaIYu0-y.d.ts +0 -6
  79. package/esm/auth/static/assets/Page-CaIYu0-y.js +0 -19
  80. package/esm/auth/static/assets/Page-MkYglNtu.css +0 -1
  81. package/esm/auth/static/assets/index-Bl0Bk5u0.d.ts +0 -64
  82. package/esm/auth/static/assets/index-Bl0Bk5u0.js +0 -2
  83. package/esm/auth/static/assets/index-R27C_TlP.css +0 -4
package/esm/common.js ADDED
@@ -0,0 +1,8 @@
1
+ // ******************************
2
+ // Objects
3
+ import { Log } from '@kitql/helpers';
4
+ // ******************************
5
+ export const ff_Log = new Log('firstly');
6
+ export const FF_Role = {
7
+ FF_Role_Admin: 'FF_Role.Admin',
8
+ };
@@ -58,7 +58,7 @@ export const cron = (jobsInfos) => {
58
58
  l.push(message);
59
59
  if (with_metadata) {
60
60
  // If the job is "stopped", there will still be a next date, but it will not fire it. The job has to start.
61
- l.push(`(${job.running ? green('running') : red('stopped')}, next at ${yellow(job.nextDate().toISO())})`);
61
+ l.push(`(${job.isActive ? green('running') : red('stopped')}, next at ${yellow(job.nextDate().toISO())})`);
62
62
  }
63
63
  if (isSuccess) {
64
64
  m.log.success(l.join(' '));
@@ -200,8 +200,7 @@ export class FeedbackController {
200
200
  items[items.length - 1].public = true;
201
201
  }
202
202
  else {
203
- const nbEye = comments[i].reactionGroups.find((c) => c.content === 'EYES')?.reactors
204
- .totalCount;
203
+ const nbEye = comments[i].reactionGroups.find((c) => c.content === 'EYES')?.reactors.totalCount;
205
204
  items.push({
206
205
  bodyHTML: comments[i].bodyHTML,
207
206
  createdAt: new Date(comments[i].createdAt),
@@ -63,61 +63,57 @@ const disableButton = (issueNumber2, title2, content2) => {
63
63
  </script>
64
64
 
65
65
  <div class="mb-4 grid gap-4">
66
- {#if state === 'loading'}
67
- <Loading class="h-12"></Loading>
68
- <Loading class="h-12"></Loading>
69
- <Loading class="h-12"></Loading>
70
- {:else}
71
- {#each issue?.items ?? [] as item}
72
- <div class="chat {item.who ? 'chat-start' : 'chat-end'}">
73
- <div class="avatar chat-image">
74
- <div class="w-10 rounded-full">
75
- <div class="h-10 w-10 {item.who ? 'bg-primary' : 'bg-secondary'}"></div>
76
- </div>
77
- </div>
78
- <div class="chat-header">
79
- {item.who ?? 'Support'}
80
- <time class="text-xs opacity-50"
81
- >{new Date(item.createdAt).toLocaleDateString()} - {new Date(
82
- item.createdAt,
83
- ).toLocaleTimeString()}</time
84
- >
85
- </div>
86
- <div class="chat-bubble prose">{@html item.bodyHTML}</div>
87
- <!-- <div class="chat-footer opacity-50">Delivered</div> -->
88
- </div>
89
- {/each}
90
- {#if issue?.highlight && issue.state === 'OPEN'}
91
- <span class="badge badge-warning">En attente de réponse de TA part 😉, oui 🫵!</span>
92
- {/if}
93
- {#if issueNumber}
94
- <button on:click={update} aria-label="Actualiser" class="divider"></button>
95
- {/if}
66
+ {#if state === 'loading'}
67
+ <Loading class="h-12"></Loading>
68
+ <Loading class="h-12"></Loading>
69
+ <Loading class="h-12"></Loading>
70
+ {:else}
71
+ {#each issue?.items ?? [] as item}
72
+ <div class="chat {item.who ? 'chat-start' : 'chat-end'}">
73
+ <div class="avatar chat-image">
74
+ <div class="w-10 rounded-full">
75
+ <div class="h-10 w-10 {item.who ? 'bg-primary' : 'bg-secondary'}"></div>
76
+ </div>
77
+ </div>
78
+ <div class="chat-header">
79
+ {item.who ?? 'Support'}
80
+ <time class="text-xs opacity-50"
81
+ >{new Date(item.createdAt).toLocaleDateString()} - {new Date(
82
+ item.createdAt,
83
+ ).toLocaleTimeString()}</time
84
+ >
85
+ </div>
86
+ <div class="chat-bubble prose">{@html item.bodyHTML}</div>
87
+ <!-- <div class="chat-footer opacity-50">Delivered</div> -->
88
+ </div>
89
+ {/each}
90
+ {#if issue?.highlight && issue.state === 'OPEN'}
91
+ <span class="badge badge-warning">En attente de réponse de TA part 😉, oui 🫵!</span>
92
+ {/if}
93
+ {#if issueNumber}
94
+ <button on:click={update} aria-label="Actualiser" class="divider"></button>
95
+ {/if}
96
96
 
97
- {#if issue?.state === 'CLOSED'}
98
- <div class="flex justify-end">
99
- <Button on:click={reOpen} class="btn-neutral">Re Ouvrir</Button>
100
- </div>
101
- {:else}
102
- {#if issueNumber === null}
103
- <Field cell={cellBuildor(repo(FilterEntity), 'title')} bind:value={title} />
104
- {/if}
105
- <Textarea
106
- bind:value={content}
107
- placeholder="Un peu de détail c'est pas mal... Fais toi Plaiz' (Tu as même le droit d'utiliser le format markdown!)"
108
- ></Textarea>
109
- <div class="flex justify-between">
110
- {#if issueNumber}
111
- <Button on:click={close} tabIndex={-1} class="btn-outline btn-error"
112
- >Clore le feedback</Button
113
- >
114
- {:else}
115
- <div></div>
116
- {/if}
117
- <Button on:click={send} disabled={disableButton(issueNumber, title, content)}
118
- >Envoyer</Button
119
- >
120
- </div>
121
- {/if}
122
- {/if}
97
+ {#if issue?.state === 'CLOSED'}
98
+ <div class="flex justify-end">
99
+ <Button on:click={reOpen} class="btn-neutral">Re Ouvrir</Button>
100
+ </div>
101
+ {:else}
102
+ {#if issueNumber === null}
103
+ <Field cell={cellBuildor(repo(FilterEntity), 'title')} bind:value={title} />
104
+ {/if}
105
+ <Textarea
106
+ bind:value={content}
107
+ placeholder="Un peu de détail c'est pas mal... Fais toi Plaiz' (Tu as même le droit d'utiliser le format markdown!)"
108
+ ></Textarea>
109
+ <div class="flex justify-between">
110
+ {#if issueNumber}
111
+ <Button on:click={close} tabIndex={-1} class="btn-outline btn-error">Clore le feedback</Button>
112
+ {:else}
113
+ <div></div>
114
+ {/if}
115
+ <Button on:click={send} disabled={disableButton(issueNumber, title, content)}>Envoyer</Button>
116
+ </div>
117
+ {/if}
118
+ {/if}
123
119
  </div>
@@ -29,77 +29,77 @@ onMount(async () => {
29
29
  </script>
30
30
 
31
31
  <div class="mb-4 grid gap-4">
32
- <div class="flex justify-between">
33
- <div>
34
- <Button
35
- class={issueState === 'OPEN' ? 'btn-primary' : 'btn-ghost'}
36
- on:click={() => update('OPEN')}>En cours</Button
37
- >
38
- <Button
39
- class={issueState === 'CLOSED' ? 'btn-primary' : 'btn-ghost'}
40
- on:click={() => update('CLOSED')}>Clos</Button
41
- >
42
- </div>
32
+ <div class="flex justify-between">
33
+ <div>
34
+ <Button
35
+ class={issueState === 'OPEN' ? 'btn-primary' : 'btn-ghost'}
36
+ on:click={() => update('OPEN')}>En cours</Button
37
+ >
38
+ <Button
39
+ class={issueState === 'CLOSED' ? 'btn-primary' : 'btn-ghost'}
40
+ on:click={() => update('CLOSED')}>Clos</Button
41
+ >
42
+ </div>
43
43
 
44
- <Button
45
- on:click={async () => {
46
- await dialog.show({
47
- component: DialogIssue,
48
- classes: { root: 'overflow-auto w-[80vh] h-[80vh]' },
49
- props: { issueNumber: null, milestoneId },
50
- detail: {
51
- caption: 'Nouveau Feedback',
52
- icon: { data: LibIcon_Search },
53
- },
54
- })
55
- await update(issueState)
56
- }}
57
- >
58
- <Icon data={LibIcon_Add}></Icon>
59
- </Button>
60
- </div>
44
+ <Button
45
+ on:click={async () => {
46
+ await dialog.show({
47
+ component: DialogIssue,
48
+ classes: { root: 'overflow-auto w-[80vh] h-[80vh]' },
49
+ props: { issueNumber: null, milestoneId },
50
+ detail: {
51
+ caption: 'Nouveau Feedback',
52
+ icon: { data: LibIcon_Search },
53
+ },
54
+ })
55
+ await update(issueState)
56
+ }}
57
+ >
58
+ <Icon data={LibIcon_Add}></Icon>
59
+ </Button>
60
+ </div>
61
61
 
62
- {#each issues as issue}
63
- <Button
64
- on:click={async () => {
65
- await dialog.show({
66
- component: DialogIssue,
67
- classes: { root: 'overflow-auto w-[80vh] h-[80vh]' },
68
- props: { issueNumber: issue.number, milestoneId },
69
- detail: {
70
- caption: '#' + issue.number + ' - ' + issue.titleHTML,
71
- icon: { data: issue.state === 'OPEN' ? LibIcon_Search : LibIcon_Check },
72
- },
73
- })
74
- await update(issueState)
75
- }}
76
- class="btn-neutral"
77
- >
78
- <div class="flex w-full justify-center justify-items-center text-left">
79
- <div class="flex-grow">
80
- <span class="text-base-content/60 mr-2 inline-block w-8 text-right text-xs italic"
81
- >#{issue.number}</span
82
- >
83
- {@html issue.titleHTML}
84
- </div>
85
- {#if issue.highlight}
86
- <span class="badge badge-warning">En attente de réponse</span>
87
- {/if}
88
- </div>
89
- </Button>
90
- {:else}
91
- {#if state === 'loading'}
92
- <Loading class="h-12"></Loading>
93
- <Loading class="h-12"></Loading>
94
- <Loading class="h-12"></Loading>
95
- {:else}
96
- <div class="flex flex-col items-center justify-center p-8 text-center text-gray-500">
97
- <div class="mb-4">
98
- <Icon data={LibIcon_Search} size="4rem"></Icon>
99
- </div>
100
- <p class="text-lg font-medium">Aucun feedback <b>{issueState}</b> pour le moment</p>
101
- <p class="mt-2 text-sm">Soyez le premier à donner votre avis sur cette version !</p>
102
- </div>
103
- {/if}
104
- {/each}
62
+ {#each issues as issue}
63
+ <Button
64
+ on:click={async () => {
65
+ await dialog.show({
66
+ component: DialogIssue,
67
+ classes: { root: 'overflow-auto w-[80vh] h-[80vh]' },
68
+ props: { issueNumber: issue.number, milestoneId },
69
+ detail: {
70
+ caption: '#' + issue.number + ' - ' + issue.titleHTML,
71
+ icon: { data: issue.state === 'OPEN' ? LibIcon_Search : LibIcon_Check },
72
+ },
73
+ })
74
+ await update(issueState)
75
+ }}
76
+ class="btn-neutral"
77
+ >
78
+ <div class="flex w-full justify-center justify-items-center text-left">
79
+ <div class="flex-grow">
80
+ <span class="text-base-content/60 mr-2 inline-block w-8 text-right text-xs italic"
81
+ >#{issue.number}</span
82
+ >
83
+ {@html issue.titleHTML}
84
+ </div>
85
+ {#if issue.highlight}
86
+ <span class="badge badge-warning">En attente de réponse</span>
87
+ {/if}
88
+ </div>
89
+ </Button>
90
+ {:else}
91
+ {#if state === 'loading'}
92
+ <Loading class="h-12"></Loading>
93
+ <Loading class="h-12"></Loading>
94
+ <Loading class="h-12"></Loading>
95
+ {:else}
96
+ <div class="flex flex-col items-center justify-center p-8 text-center text-gray-500">
97
+ <div class="mb-4">
98
+ <Icon data={LibIcon_Search} size="4rem"></Icon>
99
+ </div>
100
+ <p class="text-lg font-medium">Aucun feedback <b>{issueState}</b> pour le moment</p>
101
+ <p class="mt-2 text-sm">Soyez le premier à donner votre avis sur cette version !</p>
102
+ </div>
103
+ {/if}
104
+ {/each}
105
105
  </div>
@@ -13,26 +13,26 @@ onMount(async () => {
13
13
  </script>
14
14
 
15
15
  <div class="mb-4 grid gap-4">
16
- {#each milestones as milestone}
17
- <Button
18
- on:click={() =>
19
- dialog.show({
20
- component: DialogIssues,
21
- classes: { root: 'overflow-auto w-[85vh] h-[85vh]' },
22
- props: { milestoneNumber: milestone.number, milestoneId: milestone.id },
23
- detail: { caption: milestone.title },
24
- })}
25
- class="btn-neutral"
26
- >
27
- {milestone.title}
28
- </Button>
29
- {:else}
30
- {#if state === 'loading'}
31
- <Loading class="h-12"></Loading>
32
- <Loading class="h-12"></Loading>
33
- <Loading class="h-12"></Loading>
34
- {:else}
35
- <p>No milestones found / Filter too strict!</p>
36
- {/if}
37
- {/each}
16
+ {#each milestones as milestone}
17
+ <Button
18
+ on:click={() =>
19
+ dialog.show({
20
+ component: DialogIssues,
21
+ classes: { root: 'overflow-auto w-[85vh] h-[85vh]' },
22
+ props: { milestoneNumber: milestone.number, milestoneId: milestone.id },
23
+ detail: { caption: milestone.title },
24
+ })}
25
+ class="btn-neutral"
26
+ >
27
+ {milestone.title}
28
+ </Button>
29
+ {:else}
30
+ {#if state === 'loading'}
31
+ <Loading class="h-12"></Loading>
32
+ <Loading class="h-12"></Loading>
33
+ <Loading class="h-12"></Loading>
34
+ {:else}
35
+ <p>No milestones found / Filter too strict!</p>
36
+ {/if}
37
+ {/each}
38
38
  </div>
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 declare const ff_Log: Log;
26
- export declare const FF_Role: {
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
- // Objects
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
  // ******************************
@@ -45,22 +45,22 @@ const button = {
45
45
  </script>
46
46
 
47
47
  <Html>
48
- <Head />
49
- <Preview preview={previewText ?? title + '...'} />
50
- <Section style={main}>
51
- <Container style={container}>
52
- {#if title}
53
- <Heading style={heading}>{title}</Heading>
54
- {/if}
48
+ <Head />
49
+ <Preview preview={previewText ?? title + '...'} />
50
+ <Section style={main}>
51
+ <Container style={container}>
52
+ {#if title}
53
+ <Heading style={heading}>{title}</Heading>
54
+ {/if}
55
55
 
56
- {#each sections as s}
57
- <Text style={s.highlighted ? highlighted : paragraph}>
58
- {s.text}
59
- </Text>
60
- {#if s.cta}
61
- <Button pY={19} style={button} href={s.cta.link}>{s.cta.text}</Button>
62
- {/if}
63
- {/each}
64
- </Container>
65
- </Section>
56
+ {#each sections as s}
57
+ <Text style={s.highlighted ? highlighted : paragraph}>
58
+ {s.text}
59
+ </Text>
60
+ {#if s.cta}
61
+ <Button pY={19} style={button} href={s.cta.link}>{s.cta.text}</Button>
62
+ {/if}
63
+ {/each}
64
+ </Container>
65
+ </Section>
66
66
  </Html>
@@ -6,10 +6,7 @@ type TheStoreItem<T> = {
6
6
  globalError?: string | undefined;
7
7
  };
8
8
  export declare const storeItem: <T>(repo: Repository<T>, initValues?: TheStoreItem<T>) => {
9
- subscribe: {
10
- (this: void, run: import("svelte/store").Subscriber<TheStoreItem<T>>, invalidate?: import("svelte/store").Invalidator<TheStoreItem<T>> | undefined): import("svelte/store").Unsubscriber;
11
- (this: void, run: import("svelte/store").Subscriber<TheStoreItem<T>>, invalidate?: (() => void) | undefined): import("svelte/store").Unsubscriber;
12
- };
9
+ subscribe: (this: void, run: import("svelte/store").Subscriber<TheStoreItem<T>>, invalidate?: import("svelte/store").Invalidator<TheStoreItem<T>> | undefined) => import("svelte/store").Unsubscriber;
13
10
  create: (item: Partial<T>) => void;
14
11
  set: (newItem: TheStoreItem<T>) => void;
15
12
  /**
package/esm/storeItem.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { BROWSER } from 'esm-env';
2
2
  import { derived, get, writable } from 'svelte/store';
3
- import { ff_Log } from './';
3
+ import { ff_Log } from './common.js';
4
4
  import { isError } from './helper';
5
5
  export const storeItem = (repo, initValues = {
6
6
  item: undefined,
@@ -25,10 +25,7 @@ export type FF_FindOptions<T> = FindOptions<T> & {
25
25
  * ```
26
26
  */
27
27
  export declare const storeList: <T>(repo: Repository<T>, initValues?: TheStoreList<T>) => {
28
- subscribe: {
29
- (this: void, run: import("svelte/store").Subscriber<TheStoreList<T>>, invalidate?: import("svelte/store").Invalidator<TheStoreList<T>> | undefined): import("svelte/store").Unsubscriber;
30
- (this: void, run: import("svelte/store").Subscriber<TheStoreList<T>>, invalidate?: (() => void) | undefined): import("svelte/store").Unsubscriber;
31
- };
28
+ subscribe: (this: void, run: import("svelte/store").Subscriber<TheStoreList<T>>, invalidate?: import("svelte/store").Invalidator<TheStoreList<T>> | undefined) => import("svelte/store").Unsubscriber;
32
29
  manualSet: (info: TheStoreList<T>) => void;
33
30
  fetch: (options?: FF_FindOptions<T>, onNewData?: (items?: T[], totalCount?: number) => void) => Promise<void>;
34
31
  listen: (options?: FF_FindOptions<T>) => Promise<void>;
@@ -8,4 +8,7 @@ declare module 'remult' {
8
8
  deleteCookie(...args: Parameters<RequestEvent['cookies']['delete']>): void;
9
9
  }
10
10
  }
11
+ /**
12
+ * @deprecated will be done directly in remult when modules will be in 😉
13
+ */
11
14
  export declare const sveltekit: () => Module;
@@ -1,5 +1,8 @@
1
1
  import { remult } from 'remult';
2
2
  import { Module } from '../../api';
3
+ /**
4
+ * @deprecated will be done directly in remult when modules will be in 😉
5
+ */
3
6
  export const sveltekit = () => {
4
7
  return new Module({
5
8
  name: 'sveltekit',
@@ -57,44 +57,44 @@ const {
57
57
  </script>
58
58
 
59
59
  <button
60
- {...$trigger}
61
- use:trigger
62
- use:isAllowed={{ permission }}
63
- on:click
64
- {...$$restProps}
65
- class={tw(['btn text-white', disabled ? '' : 'btn-primary', className])}
66
- {disabled}
60
+ {...$trigger}
61
+ use:trigger
62
+ use:isAllowed={{ permission }}
63
+ on:click
64
+ {...$$restProps}
65
+ class={tw(['btn text-white', disabled ? '' : 'btn-primary', className])}
66
+ {disabled}
67
67
  >
68
- <!-- btn-outline -->
69
- <slot />
70
- {#if triggerAnnimation && isLoading}
71
- <div in:fly={{ x: -20 }}>
72
- <span class="loading loading-spinner"></span>
73
- </div>
74
- {/if}
68
+ <!-- btn-outline -->
69
+ <slot />
70
+ {#if triggerAnnimation && isLoading}
71
+ <div in:fly={{ x: -20 }}>
72
+ <span class="loading loading-spinner"></span>
73
+ </div>
74
+ {/if}
75
75
  </button>
76
76
 
77
77
  {#if $open && (disabledWhy || $$slots.tooltip)}
78
- <div
79
- {...$content}
80
- use:content
81
- transition:fade={{ duration: 100 }}
82
- class="bg-base-300 z-30 rounded-lg ring-1 ring-black"
83
- >
84
- <div {...$arrow} use:arrow></div>
85
- <div class="px-4 py-1">
86
- {#if $$slots.tooltip}
87
- <slot name="tooltip" />
88
- {:else}
89
- {disabledWhy}
90
- {/if}
91
- </div>
92
- </div>
78
+ <div
79
+ {...$content}
80
+ use:content
81
+ transition:fade={{ duration: 100 }}
82
+ class="bg-base-300 z-30 rounded-lg ring-1 ring-black"
83
+ >
84
+ <div {...$arrow} use:arrow></div>
85
+ <div class="px-4 py-1">
86
+ {#if $$slots.tooltip}
87
+ <slot name="tooltip" />
88
+ {:else}
89
+ {disabledWhy}
90
+ {/if}
91
+ </div>
92
+ </div>
93
93
  {/if}
94
94
 
95
95
  <style>
96
- .btn[disabled] {
97
- pointer-events: all;
98
- cursor: not-allowed;
99
- }
96
+ .btn[disabled] {
97
+ pointer-events: all;
98
+ cursor: not-allowed;
99
+ }
100
100
  </style>
@@ -4,8 +4,8 @@ declare const __propDef: {
4
4
  props: {
5
5
  [x: string]: any;
6
6
  isLoading?: boolean | undefined;
7
- class?: string | undefined | null;
8
- permission?: BaseEnum[] | BaseEnum | undefined;
7
+ class?: string | undefined | null | undefined;
8
+ permission?: BaseEnum<any> | BaseEnum<any>[] | undefined;
9
9
  };
10
10
  events: {
11
11
  click: MouseEvent;
@@ -12,11 +12,11 @@ async function clip(_value) {
12
12
  </script>
13
13
 
14
14
  <span
15
- role="button"
16
- tabindex="0"
17
- on:keyup={() => {}}
18
- on:click={() => clip(value)}
19
- class={`${value ? 'cursor-copy' : ''} ${extraClass}`}
15
+ role="button"
16
+ tabindex="0"
17
+ on:keyup={() => {}}
18
+ on:click={() => clip(value)}
19
+ class={`${value ? 'cursor-copy' : ''} ${extraClass}`}
20
20
  >
21
- <slot />
21
+ <slot />
22
22
  </span>
@@ -2,10 +2,10 @@ import { SvelteComponent } from "svelte";
2
2
  declare const __propDef: {
3
3
  props: {
4
4
  /**
5
- * @param value to set in the clipboard if not null.
6
- *
7
- * Don't put this on an input, if not, when a user will select the input via the mouse, this clipboard will be copied (usually you wanted to paste)!
8
- */ value: string | null;
5
+ * @param value to set in the clipboard if not null.
6
+ *
7
+ * Don't put this on an input, if not, when a user will select the input via the mouse, this clipboard will be copied (usually you wanted to paste)!
8
+ */ value: string | null;
9
9
  class?: string;
10
10
  };
11
11
  events: {