+@*
@@ -16,4 +22,68 @@
@Body
+
*@
+
+
+
+ @* *@
+
+
+
+
+
+
+
+
+
+ @Body
+
+
+
+
+
+
+
+@code {
+ bool ShowSearch { get; set; } = false;
+
+ protected override void OnInitialized()
+ {
+ MessageService.EA_ShowSearch += OnShowSearch;
+ MessageService.EA_HideSearch += OnHideSearch;
+ }
+ public void OnShowSearch()
+ {
+ ShowSearch = true;
+ InvokeAsync(() =>
+ {
+ StateHasChanged();
+ });
+ }
+ public void OnHideSearch()
+ {
+ ShowSearch = false;
+ InvokeAsync(() =>
+ {
+ StateHasChanged();
+ });
+ }
+
+ public void Dispose()
+ {
+ MessageService.EA_ShowSearch -= OnShowSearch;
+ MessageService.EA_ShowSearch -= OnHideSearch;
+ }
+
+ protected bool navLarge { get; set; } = true;
+
+ protected string sideClass { get; set; } = "sidebar";
+
+ protected void UpdateNavDisplay()
+ {
+ navLarge = !navLarge;
+ sideClass = navLarge ? "sidebar" : "sidebarSmall";
+ }
+
+}
diff --git a/MagMan.UI/Shared/MainLayout.razor.css b/MagMan.UI/Shared/MainLayout.razor.css
index 551e4b2..adba2e2 100644
--- a/MagMan.UI/Shared/MainLayout.razor.css
+++ b/MagMan.UI/Shared/MainLayout.razor.css
@@ -1,70 +1,85 @@
-.page {
- position: relative;
- display: flex;
- flex-direction: column;
+.page {
+ position: relative;
+ display: flex;
+ flex-direction: column;
}
-
main {
- flex: 1;
+ flex: 1;
}
-
-.sidebar {
- background-image: linear-gradient(180deg, rgb(5, 39, 103) 0%, #3a0647 70%);
+.sidebar,
+.sidebarSmall {
+ background-image: linear-gradient(180deg, #052767 20%, #3aa6ff 90%);
}
-
.top-row {
- background-color: #f7f7f7;
- border-bottom: 1px solid #d6d5d5;
- justify-content: flex-end;
- height: 3.5rem;
- display: flex;
- align-items: center;
+ background-color: #f7f7f7;
+ border-bottom: 1px solid #d6d5d5;
+ height: 3.5rem;
+ align-items: center;
+ /*justify-content: space-evenly;
+ display: flex;*/
+}
+.top-row ::deep a,
+.top-row .btn-link {
+ white-space: nowrap;
+ margin-left: 1.5rem;
+}
+.top-row a:first-child {
+ overflow: hidden;
+ text-overflow: ellipsis;
}
-
- .top-row ::deep a, .top-row .btn-link {
- white-space: nowrap;
- margin-left: 1.5rem;
- }
-
- .top-row a:first-child {
- overflow: hidden;
- text-overflow: ellipsis;
- }
-
@media (max-width: 640.98px) {
- .top-row:not(.auth) {
- display: none;
- }
-
- .top-row.auth {
- justify-content: space-between;
- }
-
- .top-row a, .top-row .btn-link {
- margin-left: 0;
- }
+ .top-row:not(.auth) {
+ display: none;
+ }
+ .top-row.auth {
+ justify-content: space-between;
+ }
+ .top-row a,
+ .top-row .btn-link {
+ margin-left: 0;
+ }
+}
+.bottom-row {
+ color: #dedede;
+ background-color: #000000;
+ height: 2rem;
+ align-items: center;
}
-
@media (min-width: 641px) {
- .page {
- flex-direction: row;
- }
-
- .sidebar {
- width: 250px;
- height: 100vh;
- position: sticky;
- top: 0;
- }
-
- .top-row {
- position: sticky;
- top: 0;
- z-index: 1;
- }
-
- .top-row, article {
- padding-left: 2rem !important;
- padding-right: 1.5rem !important;
- }
-}
+ .page {
+ flex-direction: row;
+ }
+ .sidebar {
+ width: 230px;
+ height: 100vh;
+ position: sticky;
+ top: 0;
+ }
+ .sidebarSmall {
+ width: 80px;
+ height: 100vh;
+ position: sticky;
+ top: 0;
+ }
+ .top-row {
+ position: sticky;
+ top: 0;
+ z-index: 1;
+ }
+ .top-row,
+ article {
+ padding-left: 2rem !important;
+ padding-right: 1.5rem !important;
+ }
+ .bottom-row {
+ position: fixed;
+ bottom: 0;
+ z-index: 1;
+ }
+ .main > div {
+ padding-left: 0.5rem !important;
+ padding-right: 0.5rem !important;
+ /*padding-left: 2rem !important;
+ padding-right: 1.5rem !important;*/
+ }
+}
\ No newline at end of file
diff --git a/MagMan.UI/Shared/MainLayout.razor.less b/MagMan.UI/Shared/MainLayout.razor.less
new file mode 100644
index 0000000..7d8c29b
--- /dev/null
+++ b/MagMan.UI/Shared/MainLayout.razor.less
@@ -0,0 +1,97 @@
+.page {
+ position: relative;
+ display: flex;
+ flex-direction: column;
+}
+
+main {
+ flex: 1;
+}
+
+.sidebar, .sidebarSmall {
+ background-image: linear-gradient(180deg, rgb(5, 39, 103) 20%, #3aa6ff 90%);
+}
+
+.top-row {
+ background-color: #f7f7f7;
+ border-bottom: 1px solid #d6d5d5;
+ height: 3.5rem;
+ align-items: center;
+ /*justify-content: space-evenly;
+ display: flex;*/
+}
+
+ .top-row ::deep a, .top-row .btn-link {
+ white-space: nowrap;
+ margin-left: 1.5rem;
+ }
+
+ .top-row a:first-child {
+ overflow: hidden;
+ text-overflow: ellipsis;
+ }
+
+@media (max-width: 640.98px) {
+ .top-row:not(.auth) {
+ display: none;
+ }
+
+ .top-row.auth {
+ justify-content: space-between;
+ }
+
+ .top-row a, .top-row .btn-link {
+ margin-left: 0;
+ }
+}
+
+.bottom-row {
+ color: #dedede;
+ background-color: #000000;
+ height: 2rem;
+ align-items: center;
+}
+
+@media (min-width: 641px) {
+ .page {
+ flex-direction: row;
+ }
+
+ .sidebar {
+ width: 230px;
+ height: 100vh;
+ position: sticky;
+ top: 0;
+ }
+
+ .sidebarSmall {
+ width: 80px;
+ height: 100vh;
+ position: sticky;
+ top: 0;
+ }
+
+ .top-row {
+ position: sticky;
+ top: 0;
+ z-index: 1;
+ }
+
+ .top-row, article {
+ padding-left: 2rem !important;
+ padding-right: 1.5rem !important;
+ }
+
+ .bottom-row {
+ position: fixed;
+ bottom: 0;
+ z-index: 1;
+ }
+
+ .main > div {
+ padding-left: 0.5rem !important;
+ padding-right: 0.5rem !important;
+ /*padding-left: 2rem !important;
+ padding-right: 1.5rem !important;*/
+ }
+}
\ No newline at end of file
diff --git a/MagMan.UI/Shared/MainLayout.razor.min.css b/MagMan.UI/Shared/MainLayout.razor.min.css
new file mode 100644
index 0000000..bab86ef
--- /dev/null
+++ b/MagMan.UI/Shared/MainLayout.razor.min.css
@@ -0,0 +1 @@
+.page{position:relative;display:flex;flex-direction:column;}main{flex:1;}.sidebar,.sidebarSmall{background-image:linear-gradient(180deg,#052767 20%,#3aa6ff 90%);}.top-row{background-color:#f7f7f7;border-bottom:1px solid #d6d5d5;height:3.5rem;align-items:center;}.top-row ::deep a,.top-row .btn-link{white-space:nowrap;margin-left:1.5rem;}.top-row a:first-child{overflow:hidden;text-overflow:ellipsis;}@media(max-width:640.98px){.top-row:not(.auth){display:none;}.top-row.auth{justify-content:space-between;}.top-row a,.top-row .btn-link{margin-left:0;}}.bottom-row{color:#dedede;background-color:#000;height:2rem;align-items:center;}@media(min-width:641px){.page{flex-direction:row;}.sidebar{width:230px;height:100vh;position:sticky;top:0;}.sidebarSmall{width:80px;height:100vh;position:sticky;top:0;}.top-row{position:sticky;top:0;z-index:1;}.top-row,article{padding-left:2rem!important;padding-right:1.5rem!important;}.bottom-row{position:fixed;bottom:0;z-index:1;}.main>div{padding-left:.5rem!important;padding-right:.5rem!important;}}
\ No newline at end of file
diff --git a/MagMan.UI/Shared/NavMenu.razor.css b/MagMan.UI/Shared/NavMenu.razor.css
index acc5f9f..a4874b0 100644
--- a/MagMan.UI/Shared/NavMenu.razor.css
+++ b/MagMan.UI/Shared/NavMenu.razor.css
@@ -1,62 +1,51 @@
-.navbar-toggler {
- background-color: rgba(255, 255, 255, 0.1);
+.navbar-toggler {
+ background-color: rgba(255, 255, 255, 0.1);
}
-
.top-row {
- height: 3.5rem;
- background-color: rgba(0,0,0,0.4);
+ height: 3.5rem;
+ background-color: rgba(0, 0, 0, 0.4);
}
-
.navbar-brand {
- font-size: 1.1rem;
+ font-size: 1.1rem;
}
-
.oi {
- width: 2rem;
- font-size: 1.1rem;
- vertical-align: text-top;
- top: -2px;
+ width: 2rem;
+ font-size: 1.1rem;
+ vertical-align: text-top;
+ top: -2px;
}
-
.nav-item {
- font-size: 0.9rem;
- padding-bottom: 0.5rem;
+ font-size: 0.9rem;
+ padding-bottom: 0.5rem;
+}
+.nav-item:first-of-type {
+ padding-top: 1rem;
+}
+.nav-item:last-of-type {
+ padding-bottom: 1rem;
+}
+.nav-item ::deep a {
+ color: #d7d7d7;
+ border-radius: 4px;
+ height: 3rem;
+ display: flex;
+ align-items: center;
+ line-height: 3rem;
}
-
- .nav-item:first-of-type {
- padding-top: 1rem;
- }
-
- .nav-item:last-of-type {
- padding-bottom: 1rem;
- }
-
- .nav-item ::deep a {
- color: #d7d7d7;
- border-radius: 4px;
- height: 3rem;
- display: flex;
- align-items: center;
- line-height: 3rem;
- }
-
.nav-item ::deep a.active {
- background-color: rgba(255,255,255,0.25);
- color: white;
+ background-color: rgba(255, 255, 255, 0.25);
+ color: white;
}
-
.nav-item ::deep a:hover {
- background-color: rgba(255,255,255,0.1);
- color: white;
+ background-color: rgba(255, 255, 255, 0.1);
+ color: white;
}
-
@media (min-width: 641px) {
- .navbar-toggler {
- display: none;
- }
-
- .collapse {
- /* Never collapse the sidebar for wide screens */
- display: block;
- }
-}
+ .navbar-toggler {
+ display: none;
+ }
+ .collapse {
+ /* Never collapse the sidebar for wide screens */
+ display: block;
+ }
+}
\ No newline at end of file
diff --git a/MagMan.UI/Shared/NavMenu.razor.less b/MagMan.UI/Shared/NavMenu.razor.less
new file mode 100644
index 0000000..e132378
--- /dev/null
+++ b/MagMan.UI/Shared/NavMenu.razor.less
@@ -0,0 +1,62 @@
+.navbar-toggler {
+ background-color: rgba(255, 255, 255, 0.1);
+}
+
+.top-row {
+ height: 3.5rem;
+ background-color: rgba(0,0,0,0.4);
+}
+
+.navbar-brand {
+ font-size: 1.1rem;
+}
+
+.oi {
+ width: 2rem;
+ font-size: 1.1rem;
+ vertical-align: text-top;
+ top: -2px;
+}
+
+.nav-item {
+ font-size: 0.9rem;
+ padding-bottom: 0.5rem;
+}
+
+ .nav-item:first-of-type {
+ padding-top: 1rem;
+ }
+
+ .nav-item:last-of-type {
+ padding-bottom: 1rem;
+ }
+
+ .nav-item ::deep a {
+ color: #d7d7d7;
+ border-radius: 4px;
+ height: 3rem;
+ display: flex;
+ align-items: center;
+ line-height: 3rem;
+ }
+
+ .nav-item ::deep a.active {
+ background-color: rgba(255,255,255,0.25);
+ color: white;
+ }
+
+ .nav-item ::deep a:hover {
+ background-color: rgba(255,255,255,0.1);
+ color: white;
+ }
+
+@media (min-width: 641px) {
+ .navbar-toggler {
+ display: none;
+ }
+
+ .collapse {
+ /* Never collapse the sidebar for wide screens */
+ display: block;
+ }
+}
\ No newline at end of file
diff --git a/MagMan.UI/Shared/NavMenu.razor.min.css b/MagMan.UI/Shared/NavMenu.razor.min.css
new file mode 100644
index 0000000..0578d67
--- /dev/null
+++ b/MagMan.UI/Shared/NavMenu.razor.min.css
@@ -0,0 +1 @@
+.navbar-toggler{background-color:rgba(255,255,255,.1);}.top-row{height:3.5rem;background-color:rgba(0,0,0,.4);}.navbar-brand{font-size:1.1rem;}.oi{width:2rem;font-size:1.1rem;vertical-align:text-top;top:-2px;}.nav-item{font-size:.9rem;padding-bottom:.5rem;}.nav-item:first-of-type{padding-top:1rem;}.nav-item:last-of-type{padding-bottom:1rem;}.nav-item ::deep a{color:#d7d7d7;border-radius:4px;height:3rem;display:flex;align-items:center;line-height:3rem;}.nav-item ::deep a.active{background-color:rgba(255,255,255,.25);color:#fff;}.nav-item ::deep a:hover{background-color:rgba(255,255,255,.1);color:#fff;}@media(min-width:641px){.navbar-toggler{display:none;}.collapse{display:block;}}
\ No newline at end of file
diff --git a/MagMan.UI/compilerconfig.json b/MagMan.UI/compilerconfig.json
new file mode 100644
index 0000000..6c616ed
--- /dev/null
+++ b/MagMan.UI/compilerconfig.json
@@ -0,0 +1,18 @@
+[
+ {
+ "outputFile": "Shared/MainLayout.razor.css",
+ "inputFile": "Shared/MainLayout.razor.less"
+ },
+ {
+ "outputFile": "Shared/NavMenu.razor.css",
+ "inputFile": "Shared/NavMenu.razor.less"
+ },
+ {
+ "outputFile": "wwwroot/css/site.css",
+ "inputFile": "wwwroot/css/site.less"
+ },
+ {
+ "outputFile": "wwwroot/css/font.css",
+ "inputFile": "wwwroot/css/font.less"
+ }
+]
\ No newline at end of file
diff --git a/MagMan.UI/compilerconfig.json.defaults b/MagMan.UI/compilerconfig.json.defaults
new file mode 100644
index 0000000..41870cc
--- /dev/null
+++ b/MagMan.UI/compilerconfig.json.defaults
@@ -0,0 +1,71 @@
+{
+ "compilers": {
+ "less": {
+ "autoPrefix": "",
+ "cssComb": "none",
+ "ieCompat": true,
+ "math": null,
+ "strictMath": false,
+ "strictUnits": false,
+ "relativeUrls": true,
+ "rootPath": "",
+ "sourceMapRoot": "",
+ "sourceMapBasePath": "",
+ "sourceMap": false
+ },
+ "sass": {
+ "autoPrefix": "",
+ "loadPaths": "",
+ "style": "expanded",
+ "relativeUrls": true,
+ "sourceMap": false
+ },
+ "nodesass": {
+ "autoPrefix": "",
+ "includePath": "",
+ "indentType": "space",
+ "indentWidth": 2,
+ "outputStyle": "nested",
+ "precision": 5,
+ "relativeUrls": true,
+ "sourceMapRoot": "",
+ "lineFeed": "",
+ "sourceMap": false
+ },
+ "stylus": {
+ "sourceMap": false
+ },
+ "babel": {
+ "sourceMap": false
+ },
+ "coffeescript": {
+ "bare": false,
+ "runtimeMode": "node",
+ "sourceMap": false
+ },
+ "handlebars": {
+ "root": "",
+ "noBOM": false,
+ "name": "",
+ "namespace": "",
+ "knownHelpersOnly": false,
+ "forcePartial": false,
+ "knownHelpers": [],
+ "commonjs": "",
+ "amd": false,
+ "sourceMap": false
+ }
+ },
+ "minifiers": {
+ "css": {
+ "enabled": true,
+ "termSemicolons": true,
+ "gzip": false
+ },
+ "javascript": {
+ "enabled": true,
+ "termSemicolons": true,
+ "gzip": false
+ }
+ }
+}
\ No newline at end of file