@tekkare/romulus 0.1.197 → 0.1.198
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/module.json
CHANGED
|
@@ -12,14 +12,28 @@ const props = withDefaults(defineProps<{
|
|
|
12
12
|
data: { name: string, value: number }[]
|
|
13
13
|
height?: keyof typeof RM_CHART_HEIGHTS | number
|
|
14
14
|
description?: string
|
|
15
|
+
/**
|
|
16
|
+
* Masque la legende, quand les libelles poses autour de l'anneau nomment
|
|
17
|
+
* deja chaque part. L'anneau reprend alors le centre du cadre.
|
|
18
|
+
*/
|
|
19
|
+
hideLegend?: boolean
|
|
15
20
|
}>(), {
|
|
16
21
|
height: 'standard',
|
|
17
22
|
description: undefined,
|
|
23
|
+
hideLegend: false,
|
|
18
24
|
})
|
|
19
25
|
|
|
20
26
|
const { theme, palette, decal } = useChartTheme()
|
|
21
27
|
|
|
22
|
-
const option = computed(() =>
|
|
28
|
+
const option = computed(() => {
|
|
29
|
+
const base = rmDonutOption(props.data, theme.value, palette.value.cat, decal.value)
|
|
30
|
+
if (!props.hideLegend) return base
|
|
31
|
+
return {
|
|
32
|
+
...base,
|
|
33
|
+
legend: { show: false },
|
|
34
|
+
series: base.series.map(serie => ({ ...serie, center: ['50%', '50%'] })),
|
|
35
|
+
}
|
|
36
|
+
})
|
|
23
37
|
</script>
|
|
24
38
|
|
|
25
39
|
<template>
|
|
@@ -40,6 +40,12 @@ export interface RmShareWorkspace {
|
|
|
40
40
|
|
|
41
41
|
export type RmShareScope = 'private' | 'people' | 'workspace' | 'template'
|
|
42
42
|
|
|
43
|
+
/** Les libelles qu'un appelant peut redire, dans la langue du dialogue. */
|
|
44
|
+
export type RmShareTexts = Partial<Record<
|
|
45
|
+
'heading' | 'privateHint' | 'peopleHint' | 'workspaceHint' | 'save',
|
|
46
|
+
string
|
|
47
|
+
>>
|
|
48
|
+
|
|
43
49
|
const props = withDefaults(
|
|
44
50
|
defineProps<{
|
|
45
51
|
modelValue: boolean
|
|
@@ -64,6 +70,11 @@ const props = withDefaults(
|
|
|
64
70
|
* l'appelant : lui seul sait lire les criteres de la vue.
|
|
65
71
|
*/
|
|
66
72
|
templateNote?: string
|
|
73
|
+
/**
|
|
74
|
+
* Libelles a remplacer. Le dialogue parle d'une vue par defaut : un autre
|
|
75
|
+
* objet partage (un projet) redit l'en-tete et les aides des portees.
|
|
76
|
+
*/
|
|
77
|
+
texts?: RmShareTexts
|
|
67
78
|
loading?: boolean
|
|
68
79
|
lang?: 'fr' | 'en'
|
|
69
80
|
}>(),
|
|
@@ -77,6 +88,7 @@ const props = withDefaults(
|
|
|
77
88
|
targetWorkspaces: () => [],
|
|
78
89
|
workspaces: () => [],
|
|
79
90
|
templateNote: '',
|
|
91
|
+
texts: () => ({}),
|
|
80
92
|
loading: false,
|
|
81
93
|
lang: 'fr',
|
|
82
94
|
},
|
|
@@ -133,6 +145,7 @@ const T = computed(() => ({
|
|
|
133
145
|
en.value
|
|
134
146
|
? `${n} ${n > 1 ? 'workspaces' : 'workspace'} selected`
|
|
135
147
|
: `${n} espace${n > 1 ? 's' : ''} retenu${n > 1 ? 's' : ''}`,
|
|
148
|
+
...props.texts,
|
|
136
149
|
}))
|
|
137
150
|
|
|
138
151
|
const scope = ref<RmShareScope>('private')
|