@saooti/octopus-sdk 37.0.6 → 37.0.8
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 +2 -2
- package/index.ts +22 -22
- package/package.json +26 -22
- package/src/App.vue +69 -60
- package/src/api/classicCrud.ts +12 -12
- package/src/api/initialize.ts +1 -1
- package/src/assets/transition.scss +34 -22
- package/src/components/display/aggregator/RssSection.vue +3 -3
- package/src/components/display/categories/CategoryChooser.vue +73 -60
- package/src/components/display/categories/CategoryFilter.vue +134 -90
- package/src/components/display/categories/CategoryList.vue +76 -62
- package/src/components/display/comments/AddCommentModal.vue +44 -44
- package/src/components/display/comments/CommentBasicView.vue +38 -30
- package/src/components/display/comments/CommentInput.vue +121 -106
- package/src/components/display/comments/CommentItem.vue +144 -102
- package/src/components/display/comments/CommentList.vue +117 -85
- package/src/components/display/comments/CommentParentInfo.vue +18 -15
- package/src/components/display/comments/CommentPlayer.vue +39 -41
- package/src/components/display/comments/CommentSection.vue +68 -53
- package/src/components/display/edit/EditBox.vue +7 -7
- package/src/components/display/edit/EditBoxRadio.vue +3 -4
- package/src/components/display/edit/EditCommentBox.vue +34 -36
- package/src/components/display/emission/EmissionInlineList.vue +75 -63
- package/src/components/display/emission/EmissionItem.vue +47 -35
- package/src/components/display/emission/EmissionList.vue +118 -83
- package/src/components/display/emission/EmissionPlayerItem.vue +89 -89
- package/src/components/display/filter/AdvancedSearch.vue +81 -73
- package/src/components/display/filter/CategorySearchFilter.vue +27 -25
- package/src/components/display/filter/DateFilter.vue +38 -38
- package/src/components/display/filter/MonetizableFilter.vue +16 -14
- package/src/components/display/filter/ProductorSearch.vue +55 -47
- package/src/components/display/filter/RubriqueChoice.vue +42 -27
- package/src/components/display/filter/RubriqueFilter.vue +130 -85
- package/src/components/display/filter/SearchOrder.vue +16 -11
- package/src/components/display/list/ListPaginate.vue +72 -70
- package/src/components/display/list/PaginateParams.vue +29 -30
- package/src/components/display/list/PaginateSection.vue +210 -0
- package/src/components/display/list/SwiperList.vue +28 -32
- package/src/components/display/live/CountDown.vue +12 -14
- package/src/components/display/live/LiveHorizontalList.vue +60 -50
- package/src/components/display/live/LiveItem.vue +42 -26
- package/src/components/display/live/LiveList.vue +92 -65
- package/src/components/display/live/RadioCurrently.vue +47 -42
- package/src/components/display/live/RadioImage.vue +40 -42
- package/src/components/display/live/RadioItem.vue +15 -22
- package/src/components/display/live/RadioList.vue +24 -21
- package/src/components/display/live/RadioPlanning.vue +105 -68
- package/src/components/display/organisation/OrganisationChooser.vue +58 -42
- package/src/components/display/organisation/OrganisationChooserLight.vue +27 -19
- package/src/components/display/participant/ParticipantItem.vue +89 -77
- package/src/components/display/participant/ParticipantList.vue +90 -60
- package/src/components/display/playlist/PlaylistItem.vue +32 -35
- package/src/components/display/playlist/PlaylistList.vue +70 -52
- package/src/components/display/playlist/PodcastList.vue +61 -50
- package/src/components/display/playlist/PodcastPlaylistInlineList.vue +47 -38
- package/src/components/display/podcasts/AnimatorsItem.vue +17 -15
- package/src/components/display/podcasts/ParticipantDescription.vue +21 -22
- package/src/components/display/podcasts/PodcastFilterList.vue +28 -26
- package/src/components/display/podcasts/PodcastImage.vue +129 -131
- package/src/components/display/podcasts/PodcastInlineList.vue +33 -29
- package/src/components/display/podcasts/PodcastInlineListClassic.vue +91 -71
- package/src/components/display/podcasts/PodcastInlineListTemplate.vue +94 -85
- package/src/components/display/podcasts/PodcastItem.vue +96 -90
- package/src/components/display/podcasts/PodcastItemInfo.vue +61 -65
- package/src/components/display/podcasts/PodcastList.vue +115 -84
- package/src/components/display/podcasts/PodcastModuleBox.vue +95 -104
- package/src/components/display/podcasts/PodcastPlayBar.vue +45 -32
- package/src/components/display/podcasts/PodcastSwiperList.vue +65 -55
- package/src/components/display/podcasts/TagList.vue +33 -37
- package/src/components/display/rubriques/RubriqueChooser.vue +70 -51
- package/src/components/display/rubriques/RubriqueList.vue +117 -89
- package/src/components/display/sharing/PlayerParameters.vue +45 -42
- package/src/components/display/sharing/QrCode.vue +52 -46
- package/src/components/display/sharing/ShareButtons.vue +18 -18
- package/src/components/display/sharing/ShareButtonsIntern.vue +100 -78
- package/src/components/display/sharing/ShareDistribution.vue +101 -67
- package/src/components/display/sharing/SharePlayer.vue +207 -127
- package/src/components/display/sharing/SharePlayerColors.vue +15 -15
- package/src/components/display/sharing/SharePlayerRadio.vue +62 -39
- package/src/components/display/sharing/SharePlayerTypes.vue +93 -55
- package/src/components/display/sharing/SubscribeButtons.vue +83 -32
- package/src/components/display/studio/RecordingItemButton.vue +3 -3
- package/src/components/form/ClassicCheckbox.vue +32 -31
- package/src/components/form/ClassicDatePicker.vue +47 -49
- package/src/components/form/ClassicInputText.vue +99 -98
- package/src/components/form/ClassicLoading.vue +11 -14
- package/src/components/form/ClassicMultiselect.vue +125 -126
- package/src/components/form/ClassicRadio.vue +15 -18
- package/src/components/form/ClassicSearch.vue +17 -23
- package/src/components/form/ClassicSelect.vue +35 -27
- package/src/components/form/{Wysiwyg.vue → ClassicWysiwyg.vue} +103 -118
- package/src/components/misc/AcpmImage.vue +6 -6
- package/src/components/misc/ClassicAccordion.vue +73 -0
- package/src/components/misc/ClassicNav.vue +117 -0
- package/src/components/misc/ClassicPopover.vue +212 -0
- package/src/components/misc/{Spinner.vue → ClassicSpinner.vue} +14 -15
- package/src/components/misc/ErrorMessage.vue +9 -17
- package/src/components/misc/FooterSection.vue +198 -0
- package/src/components/misc/HomeDropdown.vue +60 -60
- package/src/components/misc/LeftMenu.vue +115 -79
- package/src/components/misc/ProgressBar.vue +36 -32
- package/src/components/misc/SnackBar.vue +169 -0
- package/src/components/misc/TopBar.vue +162 -116
- package/src/components/misc/modal/ClassicModal.vue +99 -103
- package/src/components/misc/modal/ClipboardModal.vue +21 -23
- package/src/components/misc/modal/MessageModal.vue +22 -28
- package/src/components/misc/modal/NewsletterModal.vue +139 -113
- package/src/components/misc/modal/QrCodeModal.vue +14 -17
- package/src/components/misc/modal/ShareModalPlayer.vue +44 -60
- package/src/components/misc/player/PlayerCompact.vue +47 -62
- package/src/components/misc/player/{Player.vue → PlayerComponent.vue} +54 -46
- package/src/components/misc/player/PlayerLarge.vue +62 -61
- package/src/components/misc/player/PlayerProgressBar.vue +40 -30
- package/src/components/misc/player/PlayerTimeline.vue +32 -36
- package/src/components/misc/player/radio/RadioHistory.vue +62 -59
- package/src/components/misc/player/radio/RadioProgressBar.vue +44 -35
- package/src/components/mixins/cookies.ts +11 -10
- package/src/components/mixins/displayMethods.ts +5 -4
- package/src/components/mixins/handle403.ts +9 -9
- package/src/components/mixins/imageProxy.ts +14 -7
- package/src/components/mixins/init.ts +31 -16
- package/src/components/mixins/orgaComputed.ts +7 -7
- package/src/components/mixins/organisationFilter.ts +36 -22
- package/src/components/mixins/player/playerComment.ts +46 -37
- package/src/components/mixins/player/playerDisplay.ts +122 -87
- package/src/components/mixins/player/playerLive.ts +65 -43
- package/src/components/mixins/player/playerLogic.ts +133 -88
- package/src/components/mixins/player/playerTranscript.ts +48 -30
- package/src/components/mixins/radio/fetchRadioData.ts +40 -23
- package/src/components/mixins/selenium.ts +2 -2
- package/src/components/mixins/tagOfMixins.ts +11 -11
- package/src/components/pages/CategoryPage.vue +43 -0
- package/src/components/pages/{Emission.vue → EmissionPage.vue} +98 -67
- package/src/components/pages/{Emissions.vue → EmissionsPage.vue} +51 -44
- package/src/components/pages/Error403Page.vue +20 -19
- package/src/components/pages/HomePage.vue +144 -0
- package/src/components/pages/LivesPage.vue +66 -0
- package/src/components/pages/PageNotFound.vue +33 -22
- package/src/components/pages/{Participant.vue → ParticipantPage.vue} +63 -49
- package/src/components/pages/{Participants.vue → ParticipantsPage.vue} +9 -9
- package/src/components/pages/PlaylistPage.vue +175 -0
- package/src/components/pages/{Playlists.vue → PlaylistsPage.vue} +16 -14
- package/src/components/pages/PodcastPage.vue +365 -0
- package/src/components/pages/PodcastsPage.vue +152 -0
- package/src/components/pages/RadioPage.vue +131 -0
- package/src/components/pages/RubriquePage.vue +45 -0
- package/src/components/pages/{Search.vue → SearchPage.vue} +19 -19
- package/src/helper/dom.ts +1 -1
- package/src/helper/duration.ts +10 -4
- package/src/helper/useEventListener.ts +7 -8
- package/src/i18n.ts +31 -30
- package/src/locale/de.ts +272 -257
- package/src/locale/educationen.ts +13 -13
- package/src/locale/educationfr.ts +1 -1
- package/src/locale/en.ts +332 -324
- package/src/locale/es.ts +334 -318
- package/src/locale/fr.ts +339 -324
- package/src/locale/it.ts +341 -328
- package/src/locale/messages.ts +9 -9
- package/src/locale/sl.ts +324 -319
- package/src/main.ts +28 -31
- package/src/router/router.ts +218 -198
- package/src/shims-tsx.d.ts +1 -1
- package/src/shims-vue.d.ts +1 -1
- package/src/stores/ApiStore.ts +44 -44
- package/src/stores/AuthStore.ts +21 -15
- package/src/stores/CommentStore.ts +13 -11
- package/src/stores/FilterStore.ts +25 -15
- package/src/stores/GeneralStore.ts +15 -15
- package/src/stores/ParamSdkStore.ts +179 -137
- package/src/stores/PlayerStore.ts +139 -125
- package/src/stores/class/adserver/adserverConfig.ts +1 -1
- package/src/stores/class/adserver/adserverOtherEmission.ts +9 -9
- package/src/stores/class/cartouchier/cartouche.ts +4 -4
- package/src/stores/class/cartouchier/cartouchier.ts +2 -2
- package/src/stores/class/conference/conference.ts +10 -9
- package/src/stores/class/conference/conferenceMessage.ts +2 -2
- package/src/stores/class/conference/conferenceParticipant.ts +1 -1
- package/src/stores/class/conference/studioCall.ts +6 -6
- package/src/stores/class/contract/contractOrganisation.ts +5 -5
- package/src/stores/class/ftp/ftpEmission.ts +9 -9
- package/src/stores/class/ftp/testFtpEmission.ts +4 -4
- package/src/stores/class/general/audioView.ts +19 -19
- package/src/stores/class/general/category.ts +1 -1
- package/src/stores/class/general/classicSelectType.ts +2 -3
- package/src/stores/class/general/customPlayer.ts +8 -8
- package/src/stores/class/general/emission.ts +20 -20
- package/src/stores/class/general/fetchParam.ts +8 -2
- package/src/stores/class/general/initState.ts +31 -31
- package/src/stores/class/general/interfacePageable.ts +13 -13
- package/src/stores/class/general/ituneCategory.ts +4 -4
- package/src/stores/class/general/listReturn.ts +12 -12
- package/src/stores/class/general/media.ts +7 -7
- package/src/stores/class/general/organisation.ts +9 -9
- package/src/stores/class/general/pageable.ts +10 -10
- package/src/stores/class/general/participant.ts +7 -7
- package/src/stores/class/general/player.ts +30 -28
- package/src/stores/class/general/playlist.ts +17 -19
- package/src/stores/class/general/podcast.ts +19 -19
- package/src/stores/class/general/sortPageable.ts +4 -4
- package/src/stores/class/general/soundcastCategory.ts +7 -7
- package/src/stores/class/ouestFrance/ofTag.ts +34 -34
- package/src/stores/class/ouestFrance/ofTagInfo.ts +9 -9
- package/src/stores/class/ouestFrance/ofTagPage.ts +7 -7
- package/src/stores/class/ouestFrance/ofTagSeo.ts +7 -7
- package/src/stores/class/ouestFrance/ofTagVente.ts +6 -6
- package/src/stores/class/ouestFrance/ofTagWithParents.ts +20 -20
- package/src/stores/class/radio/canal.ts +4 -4
- package/src/stores/class/radio/live.ts +6 -6
- package/src/stores/class/radio/mix.ts +16 -16
- package/src/stores/class/radio/playlistMedia.ts +7 -7
- package/src/stores/class/radio/recurrence.ts +54 -54
- package/src/stores/class/rss/rssEmission.ts +13 -13
- package/src/stores/class/rss/rssInfo.ts +7 -7
- package/src/stores/class/rubrique/rubriquage.ts +2 -2
- package/src/stores/class/rubrique/rubrique.ts +1 -1
- package/src/stores/class/stat/statArrayIncome.ts +5 -5
- package/src/stores/class/stat/statArrayObject.ts +26 -26
- package/src/stores/class/stat/statGraph.ts +6 -6
- package/src/stores/class/user/person.ts +4 -2
- package/src/stores/class/user/profile.ts +4 -2
- package/src/stores/class/user/userKeycloak.ts +4 -5
- package/src/components/display/list/Paginate.vue +0 -181
- package/src/components/misc/Accordion.vue +0 -78
- package/src/components/misc/Footer.vue +0 -169
- package/src/components/misc/Nav.vue +0 -119
- package/src/components/misc/Popover.vue +0 -193
- package/src/components/misc/Snackbar.vue +0 -168
- package/src/components/pages/Category.vue +0 -41
- package/src/components/pages/Home.vue +0 -125
- package/src/components/pages/Lives.vue +0 -64
- package/src/components/pages/Playlist.vue +0 -164
- package/src/components/pages/Podcast.vue +0 -307
- package/src/components/pages/Podcasts.vue +0 -146
- package/src/components/pages/Radio.vue +0 -122
- package/src/components/pages/Rubrique.vue +0 -42
|
@@ -1,11 +1,8 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="wysiwyg-editor">
|
|
3
|
-
<div
|
|
4
|
-
v-if="editor"
|
|
5
|
-
class="editor-menubar"
|
|
6
|
-
>
|
|
3
|
+
<div v-if="editor" class="editor-menubar">
|
|
7
4
|
<button
|
|
8
|
-
title="Bold"
|
|
5
|
+
:title="$t('Bold')"
|
|
9
6
|
data-selenium="Bold"
|
|
10
7
|
:class="{ 'is-active': editor.isActive('bold') }"
|
|
11
8
|
@click="editor.chain().focus().toggleBold().run()"
|
|
@@ -18,7 +15,7 @@
|
|
|
18
15
|
</svg>
|
|
19
16
|
</button>
|
|
20
17
|
<button
|
|
21
|
-
title="Italic"
|
|
18
|
+
:title="$t('Italic')"
|
|
22
19
|
data-selenium="Italic"
|
|
23
20
|
:class="{ 'is-active': editor.isActive('italic') }"
|
|
24
21
|
@click="editor.chain().focus().toggleItalic().run()"
|
|
@@ -31,7 +28,7 @@
|
|
|
31
28
|
</svg>
|
|
32
29
|
</button>
|
|
33
30
|
<button
|
|
34
|
-
title="Underline"
|
|
31
|
+
:title="$t('Underline')"
|
|
35
32
|
data-selenium="Underline"
|
|
36
33
|
:class="{ 'is-active': editor.isActive('underline') }"
|
|
37
34
|
@click="editor.chain().focus().toggleUnderline().run()"
|
|
@@ -44,15 +41,12 @@
|
|
|
44
41
|
</svg>
|
|
45
42
|
</button>
|
|
46
43
|
<button
|
|
47
|
-
title="Link"
|
|
44
|
+
:title="$t('Link')"
|
|
48
45
|
data-selenium="Link"
|
|
49
46
|
:class="{ 'is-active': editor.isActive('link') }"
|
|
50
47
|
@click="setLink"
|
|
51
48
|
>
|
|
52
|
-
<svg
|
|
53
|
-
viewBox="0 0 24 24"
|
|
54
|
-
fill="none"
|
|
55
|
-
>
|
|
49
|
+
<svg viewBox="0 0 24 24" fill="none">
|
|
56
50
|
<path
|
|
57
51
|
transform="translate(2, 2)scale(0.8)"
|
|
58
52
|
d="M7.7574 10.5858L4.92897 13.4142C3.7574 14.5858 3.7574 16.4853 4.92897 17.6569L6.34319 19.0711C7.51476 20.2427 9.41425 20.2427 10.5858 19.0711L13.4143 16.2427M9.87873 14.1214L14.1214 9.87873M10.5858 7.7574L13.4142 4.92897C14.5858 3.7574 16.4853 3.7574 17.6569 4.92897L19.0711 6.34319C20.2427 7.51476 20.2427 9.41425 19.0711 10.5858L16.2427 13.4143"
|
|
@@ -67,10 +61,7 @@
|
|
|
67
61
|
:disabled="!editor.isActive('link')"
|
|
68
62
|
@click="editor.chain().focus().unsetLink().run()"
|
|
69
63
|
>
|
|
70
|
-
<svg
|
|
71
|
-
viewBox="0 0 24 24"
|
|
72
|
-
fill="none"
|
|
73
|
-
>
|
|
64
|
+
<svg viewBox="0 0 24 24" fill="none">
|
|
74
65
|
<path
|
|
75
66
|
transform="translate(2, 2)scale(0.8)"
|
|
76
67
|
d="M7.05029 11.2929L4.92897 13.4142C3.7574 14.5858 3.7574 16.4853 4.92897 17.6568L6.34319 19.0711C7.51476 20.2426 9.41425 20.2426 10.5858 19.0711L12.7071 16.9497M5.00004 5L19 19"
|
|
@@ -89,7 +80,7 @@
|
|
|
89
80
|
</svg>
|
|
90
81
|
</button>
|
|
91
82
|
<button
|
|
92
|
-
title="Heading3"
|
|
83
|
+
:title="$t('Heading3')"
|
|
93
84
|
data-selenium="Heading3"
|
|
94
85
|
:class="{ 'is-active': editor.isActive('heading', { level: 3 }) }"
|
|
95
86
|
@click="editor.chain().focus().toggleHeading({ level: 3 }).run()"
|
|
@@ -97,7 +88,7 @@
|
|
|
97
88
|
H3
|
|
98
89
|
</button>
|
|
99
90
|
<button
|
|
100
|
-
title="Heading4"
|
|
91
|
+
:title="$t('Heading4')"
|
|
101
92
|
data-selenium="Heading4"
|
|
102
93
|
:class="{ 'is-active': editor.isActive('heading', { level: 4 }) }"
|
|
103
94
|
@click="editor.chain().focus().toggleHeading({ level: 4 }).run()"
|
|
@@ -105,39 +96,24 @@
|
|
|
105
96
|
H4
|
|
106
97
|
</button>
|
|
107
98
|
<button
|
|
108
|
-
title="UnorderedList"
|
|
99
|
+
:title="$t('UnorderedList')"
|
|
109
100
|
data-selenium="UnorderedList"
|
|
110
101
|
class="saooti-ul"
|
|
111
102
|
:class="{ 'is-active': editor.isActive('bulletList') }"
|
|
112
103
|
@click="editor.chain().focus().toggleBulletList().run()"
|
|
113
104
|
>
|
|
114
105
|
<svg>
|
|
115
|
-
<circle
|
|
116
|
-
transform="translate(8, 8)"
|
|
117
|
-
cx="2.5"
|
|
118
|
-
cy="3.998"
|
|
119
|
-
r="2.5"
|
|
120
|
-
/>
|
|
106
|
+
<circle transform="translate(8, 8)" cx="2.5" cy="3.998" r="2.5" />
|
|
121
107
|
<path
|
|
122
108
|
transform="translate(8, 8)"
|
|
123
109
|
d="M8.5 5H23a1 1 0 000-2H8.5a1 1 0 000 2z"
|
|
124
110
|
/>
|
|
125
|
-
<circle
|
|
126
|
-
transform="translate(8, 8)"
|
|
127
|
-
cx="2.5"
|
|
128
|
-
cy="11.998"
|
|
129
|
-
r="2.5"
|
|
130
|
-
/>
|
|
111
|
+
<circle transform="translate(8, 8)" cx="2.5" cy="11.998" r="2.5" />
|
|
131
112
|
<path
|
|
132
113
|
transform="translate(8, 8)"
|
|
133
114
|
d="M23 11H8.5a1 1 0 000 2H23a1 1 0 000-2z"
|
|
134
115
|
/>
|
|
135
|
-
<circle
|
|
136
|
-
transform="translate(8, 8)"
|
|
137
|
-
cx="2.5"
|
|
138
|
-
cy="19.998"
|
|
139
|
-
r="2.5"
|
|
140
|
-
/>
|
|
116
|
+
<circle transform="translate(8, 8)" cx="2.5" cy="19.998" r="2.5" />
|
|
141
117
|
<path
|
|
142
118
|
transform="translate(8, 8)"
|
|
143
119
|
d="M23 19H8.5a1 1 0 000 2H23a1 1 0 000-2z"
|
|
@@ -145,7 +121,7 @@
|
|
|
145
121
|
</svg>
|
|
146
122
|
</button>
|
|
147
123
|
<button
|
|
148
|
-
title="List"
|
|
124
|
+
:title="$t('List')"
|
|
149
125
|
data-selenium="List"
|
|
150
126
|
:class="{ 'is-active': editor.isActive('orderedList') }"
|
|
151
127
|
@click="editor.chain().focus().toggleOrderedList().run()"
|
|
@@ -158,7 +134,7 @@
|
|
|
158
134
|
</svg>
|
|
159
135
|
</button>
|
|
160
136
|
<button
|
|
161
|
-
title="Display HTML"
|
|
137
|
+
:title="$t('Display HTML')"
|
|
162
138
|
data-selenium="Display-HTML"
|
|
163
139
|
class="html-button"
|
|
164
140
|
:class="{ 'is-active': isHtmlDisplay }"
|
|
@@ -170,24 +146,31 @@
|
|
|
170
146
|
<editor-content
|
|
171
147
|
v-if="!isHtmlDisplay"
|
|
172
148
|
class="form-input html-wysiwyg-content"
|
|
173
|
-
:class="{
|
|
149
|
+
:class="{
|
|
150
|
+
'border border-danger': errorDescription,
|
|
151
|
+
disabled: isDisabled,
|
|
152
|
+
}"
|
|
174
153
|
:editor="editor"
|
|
175
154
|
/>
|
|
176
155
|
<pre
|
|
177
156
|
v-else
|
|
178
157
|
class="form-input"
|
|
179
|
-
:class="{
|
|
158
|
+
:class="{
|
|
159
|
+
'border border-danger': errorDescription,
|
|
160
|
+
disabled: isDisabled,
|
|
161
|
+
}"
|
|
180
162
|
><code>{{ html }}</code></pre>
|
|
181
163
|
</div>
|
|
182
164
|
</template>
|
|
183
165
|
|
|
184
166
|
<script lang="ts">
|
|
185
|
-
import { EditorContent, Editor } from
|
|
186
|
-
import StarterKit from
|
|
187
|
-
import Underline from
|
|
188
|
-
import Link from
|
|
189
|
-
import { defineComponent } from
|
|
167
|
+
import { EditorContent, Editor } from "@tiptap/vue-3";
|
|
168
|
+
import StarterKit from "@tiptap/starter-kit";
|
|
169
|
+
import Underline from "@tiptap/extension-underline";
|
|
170
|
+
import Link from "@tiptap/extension-link";
|
|
171
|
+
import { defineComponent } from "vue";
|
|
190
172
|
export default defineComponent({
|
|
173
|
+
name: "ClassicWysiwyg",
|
|
191
174
|
components: {
|
|
192
175
|
EditorContent,
|
|
193
176
|
},
|
|
@@ -197,21 +180,23 @@ export default defineComponent({
|
|
|
197
180
|
errorDescription: { default: false, type: Boolean },
|
|
198
181
|
isDisabled: { default: false, type: Boolean },
|
|
199
182
|
},
|
|
200
|
-
emits: [
|
|
183
|
+
emits: ["update:content"],
|
|
201
184
|
data() {
|
|
202
185
|
return {
|
|
203
186
|
isHtmlDisplay: false as boolean,
|
|
204
187
|
html: this.content as string,
|
|
205
|
-
editor: null as Editor|null,
|
|
188
|
+
editor: null as Editor | null,
|
|
206
189
|
};
|
|
207
190
|
},
|
|
208
191
|
watch: {
|
|
209
192
|
content(): void {
|
|
210
|
-
if(this.content===this.html){
|
|
193
|
+
if (this.content === this.html) {
|
|
194
|
+
return;
|
|
195
|
+
}
|
|
211
196
|
this.initContent();
|
|
212
197
|
},
|
|
213
198
|
isDisabled(): void {
|
|
214
|
-
if(this.editor){
|
|
199
|
+
if (this.editor) {
|
|
215
200
|
this.editor.setOptions({
|
|
216
201
|
editable: true !== this.isDisabled,
|
|
217
202
|
});
|
|
@@ -219,21 +204,24 @@ export default defineComponent({
|
|
|
219
204
|
},
|
|
220
205
|
},
|
|
221
206
|
|
|
222
|
-
mounted(){
|
|
207
|
+
mounted() {
|
|
223
208
|
this.editor = new Editor({
|
|
224
|
-
|
|
209
|
+
extensions: [
|
|
210
|
+
StarterKit,
|
|
211
|
+
Underline,
|
|
225
212
|
Link.configure({
|
|
226
213
|
openOnClick: false,
|
|
227
|
-
})
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
214
|
+
}),
|
|
215
|
+
],
|
|
216
|
+
content: "",
|
|
217
|
+
editable: true !== this.isDisabled,
|
|
218
|
+
onUpdate: this.updateHtml,
|
|
231
219
|
});
|
|
232
220
|
this.initContent();
|
|
233
221
|
},
|
|
234
222
|
beforeUnmount() {
|
|
235
|
-
if(this.editor){
|
|
236
|
-
|
|
223
|
+
if (this.editor) {
|
|
224
|
+
this.editor.destroy();
|
|
237
225
|
}
|
|
238
226
|
},
|
|
239
227
|
|
|
@@ -245,31 +233,28 @@ export default defineComponent({
|
|
|
245
233
|
}
|
|
246
234
|
},
|
|
247
235
|
updateHtml(): void {
|
|
248
|
-
if(this.editor){
|
|
236
|
+
if (this.editor) {
|
|
249
237
|
this.html = this.editor.getHTML();
|
|
250
|
-
this.$emit(
|
|
238
|
+
this.$emit("update:content", this.html);
|
|
251
239
|
}
|
|
252
240
|
},
|
|
253
241
|
setLink() {
|
|
254
|
-
if(!this.editor){
|
|
255
|
-
const previousUrl = this.editor.getAttributes('link').href;
|
|
256
|
-
const url = window.prompt('URL', previousUrl)
|
|
257
|
-
if(!url) {
|
|
242
|
+
if (!this.editor) {
|
|
258
243
|
return;
|
|
259
244
|
}
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
245
|
+
const previousUrl = this.editor.getAttributes("link").href;
|
|
246
|
+
const url = window.prompt("URL", previousUrl);
|
|
247
|
+
if (!url) {
|
|
248
|
+
return;
|
|
249
|
+
}
|
|
250
|
+
if ("" === url) {
|
|
251
|
+
this.editor.chain().focus().extendMarkRange("link").unsetLink().run();
|
|
267
252
|
return;
|
|
268
253
|
}
|
|
269
254
|
this.editor
|
|
270
255
|
.chain()
|
|
271
256
|
.focus()
|
|
272
|
-
.extendMarkRange(
|
|
257
|
+
.extendMarkRange("link")
|
|
273
258
|
.setLink({ href: url })
|
|
274
259
|
.run();
|
|
275
260
|
},
|
|
@@ -277,55 +262,55 @@ export default defineComponent({
|
|
|
277
262
|
});
|
|
278
263
|
</script>
|
|
279
264
|
<style lang="scss">
|
|
280
|
-
@import
|
|
281
|
-
.octopus-app{
|
|
282
|
-
.wysiwyg-editor {
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
}
|
|
287
|
-
pre {
|
|
288
|
-
background: #ddd;
|
|
289
|
-
margin: 0;
|
|
290
|
-
}
|
|
291
|
-
code {
|
|
292
|
-
display: block;
|
|
293
|
-
white-space: pre-wrap;
|
|
294
|
-
width: 0;
|
|
295
|
-
flex-grow: 1;
|
|
296
|
-
}
|
|
297
|
-
.editor-menubar {
|
|
298
|
-
display: flex;
|
|
299
|
-
padding: 0.2rem;
|
|
300
|
-
flex-wrap: wrap;
|
|
301
|
-
button {
|
|
302
|
-
width: 40px;
|
|
303
|
-
height: 40px;
|
|
304
|
-
background: $octopus-secondary-color;
|
|
305
|
-
border-width: 0;
|
|
306
|
-
border-radius: $octopus-borderradius;
|
|
307
|
-
margin: 0.2rem;
|
|
308
|
-
padding: 0;
|
|
309
|
-
font-size: 1.1rem;
|
|
310
|
-
font-weight: 600;
|
|
311
|
-
&:hover,
|
|
312
|
-
&.is-active {
|
|
313
|
-
background: $primaryColorTransparent;
|
|
314
|
-
}
|
|
265
|
+
@import "@scss/_variables.scss";
|
|
266
|
+
.octopus-app {
|
|
267
|
+
.wysiwyg-editor {
|
|
268
|
+
.form-input {
|
|
269
|
+
height: 200px;
|
|
270
|
+
display: flex;
|
|
315
271
|
}
|
|
316
|
-
|
|
317
|
-
|
|
272
|
+
pre {
|
|
273
|
+
background: #ddd;
|
|
274
|
+
margin: 0;
|
|
318
275
|
}
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
276
|
+
code {
|
|
277
|
+
display: block;
|
|
278
|
+
white-space: pre-wrap;
|
|
279
|
+
width: 0;
|
|
280
|
+
flex-grow: 1;
|
|
281
|
+
}
|
|
282
|
+
.editor-menubar {
|
|
283
|
+
display: flex;
|
|
284
|
+
padding: 0.2rem;
|
|
285
|
+
flex-wrap: wrap;
|
|
286
|
+
button {
|
|
287
|
+
width: 40px;
|
|
288
|
+
height: 40px;
|
|
289
|
+
background: $octopus-secondary-color;
|
|
290
|
+
border-width: 0;
|
|
291
|
+
border-radius: $octopus-borderradius;
|
|
292
|
+
margin: 0.2rem;
|
|
293
|
+
padding: 0;
|
|
294
|
+
font-size: 1.1rem;
|
|
295
|
+
font-weight: 600;
|
|
296
|
+
&:hover,
|
|
297
|
+
&.is-active {
|
|
298
|
+
background: $primaryColorTransparent;
|
|
299
|
+
}
|
|
300
|
+
}
|
|
301
|
+
.html-button {
|
|
302
|
+
font-size: 12px;
|
|
303
|
+
}
|
|
304
|
+
svg {
|
|
305
|
+
width: 40px;
|
|
306
|
+
height: 40px;
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
.ProseMirror {
|
|
310
|
+
width: 0;
|
|
311
|
+
flex-grow: 1;
|
|
312
|
+
overflow: auto;
|
|
322
313
|
}
|
|
323
314
|
}
|
|
324
|
-
.ProseMirror {
|
|
325
|
-
width: 0;
|
|
326
|
-
flex-grow: 1;
|
|
327
|
-
overflow: auto;
|
|
328
|
-
}
|
|
329
|
-
}
|
|
330
315
|
}
|
|
331
316
|
</style>
|
|
@@ -6,21 +6,21 @@
|
|
|
6
6
|
src="/img/ACPM.webp"
|
|
7
7
|
:title="$t('Octopus is ACPM Podcast accredited')"
|
|
8
8
|
:alt="$t('Octopus is ACPM Podcast accredited')"
|
|
9
|
-
|
|
9
|
+
/>
|
|
10
10
|
</template>
|
|
11
11
|
|
|
12
12
|
<script lang="ts">
|
|
13
|
-
import { defineComponent } from
|
|
13
|
+
import { defineComponent } from "vue";
|
|
14
14
|
export default defineComponent({
|
|
15
|
-
name:
|
|
16
|
-
})
|
|
15
|
+
name: "AcpmImage",
|
|
16
|
+
});
|
|
17
17
|
</script>
|
|
18
18
|
|
|
19
19
|
<style lang="scss">
|
|
20
|
-
.octopus-app{
|
|
20
|
+
.octopus-app {
|
|
21
21
|
.acpm_image {
|
|
22
22
|
width: 44px;
|
|
23
23
|
height: 44px;
|
|
24
24
|
}
|
|
25
25
|
}
|
|
26
|
-
</style>
|
|
26
|
+
</style>
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="my-2" :class="displayAccordion ? 'octopus-accordion' : ''">
|
|
3
|
+
<template v-if="displayAccordion">
|
|
4
|
+
<button
|
|
5
|
+
:id="'accordion-' + idComposer"
|
|
6
|
+
class="btn-transparent bg-white w-100 p-2 text-start d-flex align-items-center"
|
|
7
|
+
:class="isOpen ? 'really-light-primary-bg' : ''"
|
|
8
|
+
@click="isOpen = !isOpen"
|
|
9
|
+
>
|
|
10
|
+
<span v-if="icon" class="img-accordion text-primary" :class="icon" />
|
|
11
|
+
<img
|
|
12
|
+
v-if="imageUrl"
|
|
13
|
+
width="30"
|
|
14
|
+
height="30"
|
|
15
|
+
class="img-accordion"
|
|
16
|
+
:src="imageUrl"
|
|
17
|
+
:alt="title"
|
|
18
|
+
/>
|
|
19
|
+
<span class="flex-grow-1">{{ title }}</span>
|
|
20
|
+
<span :class="isOpen ? 'saooti-up' : 'saooti-down'" />
|
|
21
|
+
</button>
|
|
22
|
+
<div v-show="isOpen" class="body p-2">
|
|
23
|
+
<slot />
|
|
24
|
+
</div>
|
|
25
|
+
</template>
|
|
26
|
+
<slot v-else />
|
|
27
|
+
</div>
|
|
28
|
+
</template>
|
|
29
|
+
|
|
30
|
+
<script lang="ts">
|
|
31
|
+
import { defineComponent } from "vue";
|
|
32
|
+
export default defineComponent({
|
|
33
|
+
name: "ClassicAccordion",
|
|
34
|
+
props: {
|
|
35
|
+
title: { default: "", type: String },
|
|
36
|
+
idComposer: { default: "", type: String },
|
|
37
|
+
icon: { default: undefined, type: String },
|
|
38
|
+
imageUrl: { default: undefined, type: String },
|
|
39
|
+
displayAccordion: { default: true, type: Boolean },
|
|
40
|
+
},
|
|
41
|
+
emits: ["open"],
|
|
42
|
+
data() {
|
|
43
|
+
return {
|
|
44
|
+
isOpen: false as boolean,
|
|
45
|
+
};
|
|
46
|
+
},
|
|
47
|
+
watch: {
|
|
48
|
+
isOpen() {
|
|
49
|
+
this.$emit("open");
|
|
50
|
+
},
|
|
51
|
+
},
|
|
52
|
+
});
|
|
53
|
+
</script>
|
|
54
|
+
<style lang="scss">
|
|
55
|
+
.octopus-accordion {
|
|
56
|
+
border: 1px solid #ccc;
|
|
57
|
+
> button {
|
|
58
|
+
height: 50px;
|
|
59
|
+
}
|
|
60
|
+
.img-accordion {
|
|
61
|
+
width: 30px;
|
|
62
|
+
height: 30px;
|
|
63
|
+
margin-right: 1rem;
|
|
64
|
+
font-size: 20px;
|
|
65
|
+
display: flex;
|
|
66
|
+
justify-content: center;
|
|
67
|
+
align-items: center;
|
|
68
|
+
}
|
|
69
|
+
.body {
|
|
70
|
+
border-top: 1px solid #ccc;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
</style>
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<ul class="octopus-nav" :class="light ? 'light' : ''">
|
|
3
|
+
<li
|
|
4
|
+
v-for="index in tabNumber"
|
|
5
|
+
v-show="hasSlot(index - 1)"
|
|
6
|
+
:key="index - 1"
|
|
7
|
+
class="octopus-nav-item"
|
|
8
|
+
>
|
|
9
|
+
<div
|
|
10
|
+
class="octopus-nav-link"
|
|
11
|
+
:class="activeTab === index - 1 ? 'active' : ''"
|
|
12
|
+
@click="$emit('update:activeTab', index - 1)"
|
|
13
|
+
>
|
|
14
|
+
<slot :name="index - 1" />
|
|
15
|
+
</div>
|
|
16
|
+
</li>
|
|
17
|
+
</ul>
|
|
18
|
+
<div :class="transparent ? 'd-flex flex-grow-1' : 'octopus-tab-content'">
|
|
19
|
+
<div
|
|
20
|
+
v-for="index in tabNumber"
|
|
21
|
+
v-show="hasSlot('tab' + (index - 1))"
|
|
22
|
+
:key="index - 1"
|
|
23
|
+
class="octopus-tab-pane"
|
|
24
|
+
:class="activeTab === index - 1 ? 'active' : ''"
|
|
25
|
+
>
|
|
26
|
+
<slot :name="'tab' + (index - 1)" :is-active="activeTab === index - 1" />
|
|
27
|
+
</div>
|
|
28
|
+
</div>
|
|
29
|
+
</template>
|
|
30
|
+
|
|
31
|
+
<script lang="ts">
|
|
32
|
+
import { defineComponent } from "vue";
|
|
33
|
+
export default defineComponent({
|
|
34
|
+
name: "ClassicNav",
|
|
35
|
+
props: {
|
|
36
|
+
tabNumber: { default: 0, type: Number },
|
|
37
|
+
activeTab: { default: 0, type: Number },
|
|
38
|
+
transparent: { default: false, type: Boolean },
|
|
39
|
+
light: { default: false, type: Boolean },
|
|
40
|
+
},
|
|
41
|
+
emits: ["update:activeTab"],
|
|
42
|
+
methods: {
|
|
43
|
+
hasSlot(name = "default") {
|
|
44
|
+
return !!this.$slots[name];
|
|
45
|
+
},
|
|
46
|
+
},
|
|
47
|
+
});
|
|
48
|
+
</script>
|
|
49
|
+
|
|
50
|
+
<style lang="scss">
|
|
51
|
+
@import "@scss/_variables.scss";
|
|
52
|
+
.octopus-app {
|
|
53
|
+
.octopus-nav {
|
|
54
|
+
display: flex;
|
|
55
|
+
flex-wrap: wrap;
|
|
56
|
+
padding-left: 0;
|
|
57
|
+
margin-bottom: 0;
|
|
58
|
+
margin-top: 0;
|
|
59
|
+
list-style: none;
|
|
60
|
+
border-bottom: 0.05rem solid #ddd;
|
|
61
|
+
&.light {
|
|
62
|
+
border: 0;
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
.octopus-nav-item {
|
|
66
|
+
border-right: solid 1px rgb(222, 226, 230);
|
|
67
|
+
border-left: solid 1px rgb(222, 226, 230);
|
|
68
|
+
border-top: solid 1px rgb(222, 226, 230);
|
|
69
|
+
border-top-left-radius: 0.25rem;
|
|
70
|
+
border-top-right-radius: 0.25rem;
|
|
71
|
+
cursor: pointer;
|
|
72
|
+
flex-grow: 1;
|
|
73
|
+
text-align: center;
|
|
74
|
+
}
|
|
75
|
+
.octopus-nav.light .octopus-nav-item {
|
|
76
|
+
border: 0;
|
|
77
|
+
flex-grow: 0;
|
|
78
|
+
}
|
|
79
|
+
.octopus-nav-link {
|
|
80
|
+
display: block;
|
|
81
|
+
padding: 0.5rem 1rem;
|
|
82
|
+
text-decoration: none;
|
|
83
|
+
transition:
|
|
84
|
+
color 0.15s ease-in-out,
|
|
85
|
+
background-color 0.15s ease-in-out,
|
|
86
|
+
border-color 0.15s ease-in-out;
|
|
87
|
+
border: 0.1rem solid transparent;
|
|
88
|
+
&:hover,
|
|
89
|
+
&.active {
|
|
90
|
+
border-color: #dee2e6;
|
|
91
|
+
border-bottom-color: $octopus-primary-color;
|
|
92
|
+
color: $octopus-primary-color;
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
.octopus-nav.light .octopus-nav-link {
|
|
96
|
+
border-top: 0 !important;
|
|
97
|
+
border-right: 0 !important;
|
|
98
|
+
border-left: 0 !important;
|
|
99
|
+
font-weight: bold;
|
|
100
|
+
}
|
|
101
|
+
.octopus-tab-content {
|
|
102
|
+
border-right: solid 1px rgb(222, 226, 230);
|
|
103
|
+
border-left: solid 1px rgb(222, 226, 230);
|
|
104
|
+
border-bottom: solid 1px rgb(222, 226, 230);
|
|
105
|
+
background-color: #f8fafc;
|
|
106
|
+
}
|
|
107
|
+
.octopus-tab-pane {
|
|
108
|
+
display: none;
|
|
109
|
+
&.active {
|
|
110
|
+
display: flex;
|
|
111
|
+
justify-content: space-between;
|
|
112
|
+
padding: 0.5rem;
|
|
113
|
+
flex-grow: 1;
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
</style>
|