Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Churros
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
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Matteo Planchet
Churros
Commits
dfd940da
Commit
dfd940da
authored
Dec 11, 2023
by
Ewen Le Bihan
Browse files
Options
Downloads
Patches
Plain Diff
feat(noel): force noel theme as default (c'est la dictature ici d'accord?)
parent
33882ea4
Branches
Branches containing commit
Tags
v1.34.0
Tags containing commit
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
packages/app/src/lib/theme.ts
+7
-2
7 additions, 2 deletions
packages/app/src/lib/theme.ts
packages/app/src/routes/users/[uid]/edit/+page.svelte
+6
-0
6 additions, 0 deletions
packages/app/src/routes/users/[uid]/edit/+page.svelte
with
13 additions
and
2 deletions
packages/app/src/lib/theme.ts
+
7
−
2
View file @
dfd940da
...
...
@@ -8,8 +8,13 @@ export const theme = writable('system', (set) => {
// It's not possible to load the theme on the server
if
(
!
browser
)
return
;
// Force Noël theme if not re-set to sth else by the user
if
(
localStorage
.
getItem
(
'
user_does_not_like_noel_theme
'
)
===
null
)
{
set
(
'
noel
'
);
}
else
{
// Try to load the theme from sessionStorage or fallback to a media query
set
(
localStorage
.
getItem
(
'
theme
'
)
??
'
system
'
);
}
});
export
const
isDark
=
writable
(
false
);
...
...
This diff is collapsed.
Click to expand it.
packages/app/src/routes/users/[uid]/edit/+page.svelte
+
6
−
0
View file @
dfd940da
...
...
@@ -28,6 +28,7 @@
import
InputText
from
'
$lib/components/InputText.svelte
'
;
import
ButtonGhost
from
'
$lib/components/ButtonGhost.svelte
'
;
import
FormNotificationSettings
from
'
$lib/components/FormNotificationSettings.svelte
'
;
import
{
browser
}
from
'
$app/environment
'
;
let
godparentRequestSendServerError
=
''
;
let
godparentRequestSending
=
false
;
...
...
@@ -248,6 +249,11 @@
noel
:
'
Noël
'
,
}
}
bind:value=
{
$theme
}
on:input=
{
()
=>
{
if
(
browser
)
window
.
localStorage
.
setItem
(
'
user_does_not_like_noel_theme
'
,
''
);
}
}
/>
{
/if
}
<h2>
Parrainages
</h2>
...
...
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