Skip to content

Commit

Permalink
Merge pull request #2899 from tvdeyen/page-select-layout
Browse files Browse the repository at this point in the history
PageSelect: Move URL to bottom
  • Loading branch information
tvdeyen authored May 28, 2024
2 parents e4b295d + fa2b1b3 commit 98293af
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 10 deletions.
19 changes: 12 additions & 7 deletions app/assets/stylesheets/alchemy/page-select.scss
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,12 @@
display: flex;
flex-direction: column;

.icon {
margin: 0 $default-margin;
fill: currentColor;
alchemy-icon {
margin-right: $default-margin;

.icon {
fill: currentColor;
}
}
}

Expand All @@ -25,11 +28,12 @@

.page-select--bottom {
font-size: $small-font-size;
padding-left: $default-padding;
padding-left: $default-padding / 2;
}

.page-select--site-name {
.page-select--page-urlname {
color: $muted-text-color;
padding-right: $default-padding;

.select2-highlighted & {
color: $medium-gray;
Expand All @@ -42,16 +46,17 @@
margin-left: auto;
border-radius: $default-border-radius;
padding: $default-padding / 2 $default-padding;
text-transform: uppercase;

.select2-highlighted & {
color: $select-hover-bg-color;
background-color: white;
}
}

.page-select--page-urlname {
.page-select--site-name {
margin-left: auto;
padding: $default-padding 2 * $default-padding;
padding: $default-padding 0 $default-padding 2 * $default-padding;
color: $dark-gray;
font-size: $small-font-size;

Expand Down
6 changes: 3 additions & 3 deletions app/javascript/alchemy_admin/components/page_select.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,11 @@ class PageSelect extends RemoteSelect {
<div class="page-select--top">
<alchemy-icon name="file-3"></alchemy-icon>
<span class="page-select--page-name">${page.name}</span>
<span class="page-select--page-urlname">${page.url_path}</span>
<span class="page-select--site-name">${page.site.name}</span>
</div>
<div class="page-select--bottom">
<span class="page-select--site-name">${page.site.name}</span>
<span class="page-select--language-code">${page.language.name}</span>
<span class="page-select--page-urlname">${page.url_path}</span>
<span class="page-select--language-code">${page.language_code}</span>
</div>
</div>
`
Expand Down

0 comments on commit 98293af

Please sign in to comment.