@paris-ias/list 1.0.11 → 1.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.
- package/README.md +71 -51
- package/dist/module.d.mts +8 -0
- package/dist/module.json +9 -0
- package/dist/module.mjs +64 -0
- package/dist/runtime/components/events/Badges.vue +5 -7
- package/dist/runtime/components/events/DateTimePlace.vue +11 -13
- package/dist/runtime/components/events/DenseItem.vue +7 -6
- package/dist/runtime/components/events/ExpandedItem.vue +3 -5
- package/dist/runtime/components/events/ListContainer.vue +6 -6
- package/dist/runtime/components/events/RegisterModal.vue +4 -5
- package/dist/runtime/components/events/RelatedItem.vue +6 -7
- package/dist/runtime/components/events/RowsItem.vue +12 -11
- package/dist/runtime/components/events/View.vue +10 -13
- package/dist/runtime/components/fellowships/Badges.vue +12 -15
- package/dist/runtime/components/fellowships/DenseItem.vue +7 -7
- package/dist/runtime/components/fellowships/RegisterModal.vue +3 -2
- package/dist/runtime/components/fellowships/RowsItem.vue +19 -21
- package/dist/runtime/components/fellowships/View.vue +43 -49
- package/dist/runtime/components/list/atoms/FiltersMenu.vue +6 -8
- package/dist/runtime/components/list/atoms/SearchInput.vue +42 -50
- package/dist/runtime/components/list/atoms/SearchItem.vue +14 -14
- package/dist/runtime/components/list/atoms/SearchString.vue +6 -7
- package/dist/runtime/components/list/atoms/SortMenu.vue +23 -40
- package/dist/runtime/components/list/atoms/ViewMenu.vue +14 -22
- package/dist/runtime/components/list/inputs/AutoComplete.vue +9 -9
- package/dist/runtime/components/list/inputs/BooleanSwitch.vue +9 -9
- package/dist/runtime/components/list/inputs/Checkbox.vue +11 -11
- package/dist/runtime/components/list/inputs/Select.vue +11 -11
- package/dist/runtime/components/list/molecules/Filters.vue +27 -42
- package/dist/runtime/components/list/molecules/Header.vue +5 -7
- package/dist/runtime/components/list/molecules/Pagination.vue +60 -102
- package/dist/runtime/components/list/organisms/List.vue +28 -36
- package/dist/runtime/components/list/views/Dense.vue +1 -14
- package/dist/runtime/components/list/views/Grid.vue +3 -3
- package/dist/runtime/components/list/views/Rows.vue +3 -3
- package/dist/runtime/components/list/views/Table.vue +3 -3
- package/dist/runtime/components/misc/atoms/CountUp.vue +89 -144
- package/dist/runtime/components/misc/atoms/DateStamp.vue +42 -46
- package/dist/runtime/components/misc/atoms/ImageContainer.vue +14 -22
- package/dist/runtime/components/misc/atoms/ShareMenu.vue +9 -11
- package/dist/runtime/components/misc/atoms/Socials.vue +46 -52
- package/dist/runtime/components/misc/molecules/ChipContainer.vue +7 -11
- package/dist/runtime/components/misc/molecules/Related.vue +9 -11
- package/dist/runtime/components/misc/molecules/RelatedItems.vue +7 -9
- package/dist/runtime/components/misc/molecules/SearchItem.vue +2 -2
- package/dist/runtime/components/news/DenseItem.vue +15 -15
- package/dist/runtime/components/news/ExpandedItem.vue +40 -50
- package/dist/runtime/components/news/Header.vue +3 -5
- package/dist/runtime/components/news/RelatedItem.vue +6 -7
- package/dist/runtime/components/news/RowsItem.vue +14 -16
- package/dist/runtime/components/news/View.vue +9 -20
- package/dist/runtime/components/people/DenseItem.vue +9 -8
- package/dist/runtime/components/people/ExpandedItem.vue +4 -6
- package/dist/runtime/components/people/GroupBadges.vue +6 -8
- package/dist/runtime/components/people/RelatedItem.vue +6 -7
- package/dist/runtime/components/people/RowsItem.vue +12 -19
- package/dist/runtime/components/people/View.vue +7 -7
- package/dist/runtime/components/projects/ExpandedItem.vue +4 -6
- package/dist/runtime/components/projects/RelatedItem.vue +6 -7
- package/dist/runtime/components/projects/RowsItem.vue +21 -26
- package/dist/runtime/components/projects/View.vue +8 -8
- package/dist/runtime/components/publications/RelatedItem.vue +6 -7
- package/dist/runtime/components/publications/RowsItem.vue +20 -22
- package/dist/runtime/components/publications/View.vue +9 -15
- package/dist/runtime/composables/useFetchItem.d.ts +6 -0
- package/dist/runtime/composables/useFetchItem.js +49 -0
- package/dist/runtime/composables/useIcons.d.ts +1 -0
- package/dist/runtime/composables/useIcons.js +30 -0
- package/dist/runtime/composables/useUtils.d.ts +12 -0
- package/dist/runtime/composables/useUtils.js +47 -0
- package/dist/runtime/plugins/pinia.d.ts +2 -0
- package/dist/runtime/plugins/{pinia.ts → pinia.js} +29 -48
- package/dist/runtime/plugins/vuetify.d.ts +2 -0
- package/dist/runtime/server/tsconfig.json +3 -0
- package/dist/runtime/stores/factory.d.ts +1 -0
- package/dist/runtime/stores/{factory.ts → factory.js} +9 -9
- package/dist/runtime/stores/root.d.ts +34 -0
- package/dist/runtime/stores/root.js +227 -0
- package/dist/types.d.mts +3 -0
- package/package.json +55 -26
- package/dist/runtime/composables/useFetchItem.ts +0 -64
- package/dist/runtime/composables/useIcons.ts +0 -30
- package/dist/runtime/composables/useUtils.ts +0 -75
- package/dist/runtime/stores/root.ts +0 -353
- package/example/.env.example +0 -3
- package/example/nuxt.config.ts +0 -19
- package/example/pages/index.vue +0 -27
- package/index.ts +0 -119
package/index.ts
DELETED
|
@@ -1,119 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
defineNuxtModule,
|
|
3
|
-
createResolver,
|
|
4
|
-
addComponentsDir,
|
|
5
|
-
addImportsDir,
|
|
6
|
-
addPlugin,
|
|
7
|
-
} from "@nuxt/kit"
|
|
8
|
-
import { fileURLToPath } from "node:url"
|
|
9
|
-
|
|
10
|
-
export interface ModuleOptions {
|
|
11
|
-
modules: string[]
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
export default defineNuxtModule<ModuleOptions>({
|
|
15
|
-
meta: {
|
|
16
|
-
name: "@paris-ias/list",
|
|
17
|
-
configKey: "list",
|
|
18
|
-
compatibility: {
|
|
19
|
-
nuxt: "^3.0.0",
|
|
20
|
-
},
|
|
21
|
-
},
|
|
22
|
-
defaults: {
|
|
23
|
-
modules: [],
|
|
24
|
-
},
|
|
25
|
-
setup(options, nuxt) {
|
|
26
|
-
const { resolve } = createResolver(import.meta.url)
|
|
27
|
-
const runtimeDir = fileURLToPath(new URL("./dist/runtime", import.meta.url))
|
|
28
|
-
|
|
29
|
-
// Add components
|
|
30
|
-
addComponentsDir({
|
|
31
|
-
path: resolve(runtimeDir, "components"),
|
|
32
|
-
global: true,
|
|
33
|
-
})
|
|
34
|
-
// Add store
|
|
35
|
-
nuxt.hook("modules:before", () => {
|
|
36
|
-
nuxt.options.build.transpile.push(resolve(runtimeDir, "stores"))
|
|
37
|
-
})
|
|
38
|
-
// Add composables
|
|
39
|
-
addImportsDir(resolve(runtimeDir, "composables"))
|
|
40
|
-
|
|
41
|
-
// Add graphQL queries
|
|
42
|
-
addImportsDir(resolve(runtimeDir, "graphql"))
|
|
43
|
-
|
|
44
|
-
// Add plugin
|
|
45
|
-
addPlugin(resolve(runtimeDir, "plugins/pinia.ts"))
|
|
46
|
-
addPlugin(resolve(runtimeDir, "plugins/vuetify.js"))
|
|
47
|
-
|
|
48
|
-
// Add translations
|
|
49
|
-
|
|
50
|
-
nuxt.hook("i18n:registerModule", (register) => {
|
|
51
|
-
register({
|
|
52
|
-
// langDir path needs to be resolved
|
|
53
|
-
langDir: resolve(runtimeDir, "translations"),
|
|
54
|
-
locales: [
|
|
55
|
-
{
|
|
56
|
-
code: "en",
|
|
57
|
-
file: "en.json",
|
|
58
|
-
},
|
|
59
|
-
{
|
|
60
|
-
code: "fr",
|
|
61
|
-
file: "fr.json",
|
|
62
|
-
},
|
|
63
|
-
],
|
|
64
|
-
})
|
|
65
|
-
})
|
|
66
|
-
nuxt.options.runtimeConfig.public.list = options
|
|
67
|
-
|
|
68
|
-
// Add i18n configuration
|
|
69
|
-
nuxt.options.i18n = {
|
|
70
|
-
...nuxt.options.i18n,
|
|
71
|
-
langDir: resolve(runtimeDir, "translations"),
|
|
72
|
-
lazy: true,
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
// Add Apollo configuration
|
|
76
|
-
nuxt.options.apollo = {
|
|
77
|
-
...nuxt.options.apollo,
|
|
78
|
-
clients: {
|
|
79
|
-
default: {
|
|
80
|
-
httpEndpoint: process.env.GRAPHQL_ENDPOINT || "",
|
|
81
|
-
httpLinkOptions: {
|
|
82
|
-
headers: {
|
|
83
|
-
"x-api-key": process.env.GRAPHQL_API_KEY || "",
|
|
84
|
-
},
|
|
85
|
-
},
|
|
86
|
-
},
|
|
87
|
-
},
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
// Add Vuetify configuration
|
|
91
|
-
nuxt.options.build.transpile = [
|
|
92
|
-
...(nuxt.options.build.transpile || []),
|
|
93
|
-
"vuetify",
|
|
94
|
-
]
|
|
95
|
-
nuxt.options.css = [
|
|
96
|
-
...(nuxt.options.css || []),
|
|
97
|
-
"vuetify/lib/styles/main.sass",
|
|
98
|
-
]
|
|
99
|
-
|
|
100
|
-
// Add Vite configuration
|
|
101
|
-
nuxt.options.vite = {
|
|
102
|
-
...nuxt.options.vite,
|
|
103
|
-
define: {
|
|
104
|
-
...nuxt.options.vite?.define,
|
|
105
|
-
"process.env.DEBUG": false,
|
|
106
|
-
},
|
|
107
|
-
css: {
|
|
108
|
-
preprocessorOptions: {
|
|
109
|
-
scss: {
|
|
110
|
-
api: "modern-compiler",
|
|
111
|
-
},
|
|
112
|
-
},
|
|
113
|
-
},
|
|
114
|
-
build: {
|
|
115
|
-
target: "esnext",
|
|
116
|
-
},
|
|
117
|
-
}
|
|
118
|
-
},
|
|
119
|
-
})
|