From 4076835889998f3ad3232372c16cfd5478ab6aae Mon Sep 17 00:00:00 2001 From: Bello Babakolo Date: Tue, 17 Sep 2024 12:12:52 +0100 Subject: [PATCH] chore: fix menu and icon --- .../images/restore_commerce_logo_square.svg | 57 ++++++------- packages/core/config/src/lib/constants/app.ts | 2 +- .../drawer-navigation-item.component.html | 5 +- .../drawer-navigation-item.component.ts | 2 +- .../organisms/header/banner.component.html | 4 +- .../json-editor/json-editor.component.ts | 1 + .../private/private-template.component.html | 14 ++-- .../modules/ui/src/lib/styles/drawer.scss | 80 +------------------ packages/modules/ui/src/lib/styles/index.scss | 1 + .../modules/ui/src/lib/styles/sidebar.scss | 2 + 10 files changed, 52 insertions(+), 116 deletions(-) mode change 100755 => 100644 apps/restorecommerce/src/assets/images/restore_commerce_logo_square.svg diff --git a/apps/restorecommerce/src/assets/images/restore_commerce_logo_square.svg b/apps/restorecommerce/src/assets/images/restore_commerce_logo_square.svg old mode 100755 new mode 100644 index 467f7a86..1b8a7425 --- a/apps/restorecommerce/src/assets/images/restore_commerce_logo_square.svg +++ b/apps/restorecommerce/src/assets/images/restore_commerce_logo_square.svg @@ -2,28 +2,27 @@ + inkscape:export-filename="restore_commerce_logo_square.png" + inkscape:export-xdpi="250" + inkscape:export-ydpi="250" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns="http://www.w3.org/2000/svg" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:dc="http://purl.org/dc/elements/1.1/"> + inkscape:swatch="solid"> + inkscape:snap-page="true" + inkscape:pagecheckerboard="0" + inkscape:deskcolor="#d1d1d1"> + originy="-920.61602px" + spacingy="1" + spacingx="1" + units="px" /> @@ -217,7 +221,7 @@ image/svg+xml - + @@ -276,15 +280,14 @@ R + style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:123.518px;line-height:125%;font-family:Lato;-inkscape-font-specification:Lato;text-align:start;writing-mode:lr-tb;text-anchor:start;fill:#ffffff">R diff --git a/packages/core/config/src/lib/constants/app.ts b/packages/core/config/src/lib/constants/app.ts index 3fc3cf83..51087d96 100644 --- a/packages/core/config/src/lib/constants/app.ts +++ b/packages/core/config/src/lib/constants/app.ts @@ -15,7 +15,7 @@ const supported: ILanguage[] = [ export const APP: Readonly = { name, - logoUrl: '/assets/images/restore_commerce_logo_full.png', + logoUrl: '/assets/images/restore_commerce_logo_square.svg', languages: { default: { ...supported[0], diff --git a/packages/modules/ui/src/lib/components/organisms/drawer/drawer-navigation-item.component.html b/packages/modules/ui/src/lib/components/organisms/drawer/drawer-navigation-item.component.html index 7be9831a..9efbed22 100644 --- a/packages/modules/ui/src/lib/components/organisms/drawer/drawer-navigation-item.component.html +++ b/packages/modules/ui/src/lib/components/organisms/drawer/drawer-navigation-item.component.html @@ -4,11 +4,12 @@ role="menuitem" >
-
+
+ > +
diff --git a/packages/modules/ui/src/lib/components/organisms/drawer/drawer-navigation-item.component.ts b/packages/modules/ui/src/lib/components/organisms/drawer/drawer-navigation-item.component.ts index d3d04a83..b8aed30c 100644 --- a/packages/modules/ui/src/lib/components/organisms/drawer/drawer-navigation-item.component.ts +++ b/packages/modules/ui/src/lib/components/organisms/drawer/drawer-navigation-item.component.ts @@ -32,7 +32,7 @@ import { RcDrawerNavigationComponent } from './drawer-navigation.component'; styles: [ ` .navigation-item-label > div.row { - font-size: 2.5rem; + font-size: 1rem; } `, ], diff --git a/packages/modules/ui/src/lib/components/organisms/header/banner.component.html b/packages/modules/ui/src/lib/components/organisms/header/banner.component.html index 03ec9424..fc805c89 100644 --- a/packages/modules/ui/src/lib/components/organisms/header/banner.component.html +++ b/packages/modules/ui/src/lib/components/organisms/header/banner.component.html @@ -6,8 +6,8 @@ [ngSrc]="logoUrl" class="responsive-image logo" role="presentation" - width="91" - height="30" + width="32" + height="32" /> diff --git a/packages/modules/ui/src/lib/components/organisms/json-editor/json-editor.component.ts b/packages/modules/ui/src/lib/components/organisms/json-editor/json-editor.component.ts index 1f21fb4a..f4838582 100644 --- a/packages/modules/ui/src/lib/components/organisms/json-editor/json-editor.component.ts +++ b/packages/modules/ui/src/lib/components/organisms/json-editor/json-editor.component.ts @@ -18,6 +18,7 @@ export class JSONEditorComponent implements AfterViewInit, OnDestroy { @HostBinding('class') classNames = 'col w-100p'; editor!: ace.Ace.Editor; + // TODO Make this private and provide an external data accessor value @Input() value = ''; diff --git a/packages/modules/ui/src/lib/components/templates/private/private-template.component.html b/packages/modules/ui/src/lib/components/templates/private/private-template.component.html index 0666b01c..80daec1f 100644 --- a/packages/modules/ui/src/lib/components/templates/private/private-template.component.html +++ b/packages/modules/ui/src/lib/components/templates/private/private-template.component.html @@ -64,24 +64,26 @@ icon="mdi:receipt-outline" [routerLink]="ROUTER.pages.main.children.orders.link" [routerLinkActive]="['selected']" - /> + >Orders - + >Products - + >Invoices + >Fulfillments diff --git a/packages/modules/ui/src/lib/styles/drawer.scss b/packages/modules/ui/src/lib/styles/drawer.scss index b1236cb9..e37ac504 100644 --- a/packages/modules/ui/src/lib/styles/drawer.scss +++ b/packages/modules/ui/src/lib/styles/drawer.scss @@ -1,77 +1,3 @@ -// // Sidebar stuff -// .drawer-content { -// $color-alpha: 0.4; - -// // Workaround to support drawer content margin left -// // margin-left: 0 !important; - -// .drawer-open + main.rc-main { -// margin-left: 147px !important; -// transition: 0.3s; -// } - -// .rc-drawer-navigation { -// height: 100%; - -// & .navigation { -// /* height: 100% */ -// overflow: hidden; - -// &:hover { -// overflow-y: auto; -// overflow-y: overlay; -// -ms-overflow-style: -ms-autohiding-scrollbar; -// } - -// margin-bottom: 0; - -// & .navigation-item { -// text-align: center; - -// & vcl-icogram, -// & vcl-icon, -// & .icogram, -// & .icon { -// display: block; - -// .icon { -// font-size: 2.3em; -// margin: 0; -// display: block; -// } - -// .text { -// font-size: 0.85em; -// width: 9em; -// display: inline-block; -// overflow: hidden; -// white-space: normal; -// margin-top: 0.6em; -// } -// } -// } - -// // Workaround to support programmatic hovering -// // Removes the :hover effect of a nav label if the .hovered class is not present -// & .navigation-item:not(.selected) { -// & .navigation-item-label:hover:not(.hovered) { -// color: inherit; -// background-color: transparent; -// } -// } -// } - -// & .level2 { -// background-color: rgba(250, 250, 250, $color-alpha); -// z-index: 1; -// box-shadow: 3px 0 3px 0 rgba(0, 0, 0, $color-alpha); -// } - -// & .rc-drawer-navigation-submenu-arrow { -// text-align: right; -// position: absolute; -// top: 0; -// right: 0; -// } -// } -// } +.drawer.drawer-open { + width: 15rem; +} diff --git a/packages/modules/ui/src/lib/styles/index.scss b/packages/modules/ui/src/lib/styles/index.scss index 26d6ed7b..8608ad25 100644 --- a/packages/modules/ui/src/lib/styles/index.scss +++ b/packages/modules/ui/src/lib/styles/index.scss @@ -1,6 +1,7 @@ @use './console.scss'; @use './app.scss'; @use './badge.scss'; +@use './drawer.scss'; @use './forms.scss'; @use './orders.scss'; @use './page.scss'; diff --git a/packages/modules/ui/src/lib/styles/sidebar.scss b/packages/modules/ui/src/lib/styles/sidebar.scss index 99b5c09a..1646075f 100644 --- a/packages/modules/ui/src/lib/styles/sidebar.scss +++ b/packages/modules/ui/src/lib/styles/sidebar.scss @@ -85,5 +85,7 @@ rc-header.application-header .logo { .cdk-overlay-pane { & > .rc-drawer-navigation { background-color: transparent; + width: 15em; + font-size: 1rem; } }