Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
dashboard
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
AURA
dashboard
Commits
5256c765
Commit
5256c765
authored
1 year ago
by
Konrad Mohrfeldt
Browse files
Options
Downloads
Patches
Plain Diff
refactor: refactor section wrapper into separate component
parent
aa707763
No related branches found
No related tags found
No related merge requests found
Pipeline
#3497
passed
1 year ago
Stage: test
Stage: release
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/components/generic/ASection.vue
+19
-0
19 additions, 0 deletions
src/components/generic/ASection.vue
src/components/shows/Schedules.vue
+6
-8
6 additions, 8 deletions
src/components/shows/Schedules.vue
src/components/shows/TimeSlotList.vue
+5
-6
5 additions, 6 deletions
src/components/shows/TimeSlotList.vue
with
30 additions
and
14 deletions
src/components/generic/ASection.vue
0 → 100644
+
19
−
0
View file @
5256c765
<
template
>
<section>
<header
class=
"tw-relative tw-w-fit tw-flex tw-items-center tw-gap-6 tw-mt-12 tw-mb-4"
>
<SectionTitle>
{{
title
}}
</SectionTitle>
<slot
name=
"header"
/>
</header>
<slot
/>
</section>
</
template
>
<
script
lang=
"ts"
setup
>
import
SectionTitle
from
'
@/components/generic/SectionTitle.vue
'
defineOptions
({
compatConfig
:
{
MODE
:
3
}
})
defineProps
<
{
title
:
string
}
>
()
</
script
>
This diff is collapsed.
Click to expand it.
src/components/shows/Schedules.vue
+
6
−
8
View file @
5256c765
<
template
>
<
template
>
<section>
<ASection
:title=
"t('showSchedules.title')"
>
<header
class=
"tw-flex tw-items-center tw-gap-6 tw-mt-12 tw-mb-4"
>
<template
#header
>
<SectionTitle>
{{
t
(
'
showSchedules.title
'
)
}}
</SectionTitle>
<button
<button
v-if=
"collapseSchedules"
v-if=
"collapseSchedules"
type=
"button"
type=
"button"
...
@@ -13,7 +11,7 @@
...
@@ -13,7 +11,7 @@
>
>
{{
t
(
isCollapsed
?
'
showSchedules.showAll
'
:
'
showSchedules.hide
'
)
}}
{{
t
(
isCollapsed
?
'
showSchedules.showAll
'
:
'
showSchedules.hide
'
)
}}
</button>
</button>
</
header
>
</
template
>
<Collapse
<Collapse
id=
"schedule-collapsable"
id=
"schedule-collapsable"
...
@@ -86,7 +84,7 @@
...
@@ -86,7 +84,7 @@
</table>
</table>
</div>
</div>
</Collapse>
</Collapse>
</
s
ection>
</
AS
ection>
</template>
</template>
<
script
lang=
"ts"
setup
>
<
script
lang=
"ts"
setup
>
...
@@ -98,9 +96,9 @@ import { useRRule } from '@/mixins/rrules'
...
@@ -98,9 +96,9 @@ import { useRRule } from '@/mixins/rrules'
import
{
usePretty
}
from
'
@/mixins/prettyDate
'
import
{
usePretty
}
from
'
@/mixins/prettyDate
'
import
{
lowercaseFirst
,
uppercaseFirst
,
useSelectedShow
}
from
'
@/utilities
'
import
{
lowercaseFirst
,
uppercaseFirst
,
useSelectedShow
}
from
'
@/utilities
'
import
{
useI18n
}
from
'
@/i18n
'
import
{
useI18n
}
from
'
@/i18n
'
import
SectionTitle
from
'
@/components/generic/SectionTitle.vue
'
import
Collapse
from
'
@/components/generic/Collapse.vue
'
import
{
Schedule
}
from
'
@/types
'
import
{
Schedule
}
from
'
@/types
'
import
Collapse
from
'
@/components/generic/Collapse.vue
'
import
ASection
from
'
@/components/generic/ASection.vue
'
defineOptions
({
defineOptions
({
compatConfig
:
{
MODE
:
3
},
compatConfig
:
{
MODE
:
3
},
...
...
This diff is collapsed.
Click to expand it.
src/components/shows/TimeSlotList.vue
+
5
−
6
View file @
5256c765
<
template
>
<
template
>
<section>
<ASection
:title=
"t('showTimeslots.title')"
>
<header
class=
"tw-flex tw-items-center tw-gap-6 tw-mt-12 tw-mb-4"
>
<template
#header
>
<SectionTitle>
{{
t
(
'
showTimeslots.title
'
)
}}
</SectionTitle>
<Popover
class=
"tw-relative"
>
<Popover
class=
"tw-relative"
>
<!-- TODO: this span is on purpose because headless ui seems to interfere with vue compat -->
<!-- TODO: this span is on purpose because headless ui seems to interfere with vue compat -->
<PopoverButton
as=
"span"
>
<PopoverButton
as=
"span"
>
...
@@ -18,7 +17,7 @@
...
@@ -18,7 +17,7 @@
<TimeSlotFilter
v-model=
"page"
class=
"tw-flex-col"
@
paginate=
"paginationData = $event"
/>
<TimeSlotFilter
v-model=
"page"
class=
"tw-flex-col"
@
paginate=
"paginationData = $event"
/>
</PopoverPanel>
</PopoverPanel>
</Popover>
</Popover>
</
header
>
</
template
>
<div
class=
"aura-table-wrapper"
>
<div
class=
"aura-table-wrapper"
>
<table
ref=
"tableEl"
class=
"aura-table"
>
<table
ref=
"tableEl"
class=
"aura-table"
>
...
@@ -61,7 +60,7 @@
...
@@ -61,7 +60,7 @@
/>
/>
</div>
</div>
</div>
</div>
</
s
ection>
</
AS
ection>
</template>
</template>
<
script
lang=
"ts"
setup
>
<
script
lang=
"ts"
setup
>
...
@@ -74,7 +73,7 @@ import TimeSlotRow from '@/components/shows/TimeSlotRow.vue'
...
@@ -74,7 +73,7 @@ import TimeSlotRow from '@/components/shows/TimeSlotRow.vue'
import
{
PaginationData
}
from
'
@/types
'
import
{
PaginationData
}
from
'
@/types
'
import
Pagination
from
'
@/components/generic/Pagination.vue
'
import
Pagination
from
'
@/components/generic/Pagination.vue
'
import
PaginationRange
from
'
@/components/generic/PaginationRange.vue
'
import
PaginationRange
from
'
@/components/generic/PaginationRange.vue
'
import
Section
Title
from
'
@/components/generic/Section
Title
.vue
'
import
A
Section
from
'
@/components/generic/
A
Section.vue
'
defineOptions
({
defineOptions
({
compatConfig
:
{
MODE
:
3
},
compatConfig
:
{
MODE
:
3
},
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment