-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
50 additions
and
63 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
61 changes: 19 additions & 42 deletions
61
...taiga-lumbermill/src/dashboards/iot/components/control-panel/control-panel.component.less
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,64 +1,41 @@ | ||
.actions { | ||
display: grid; | ||
grid-template-columns: 1fr 1fr; | ||
gap: 1.25rem; | ||
:host { | ||
display: flex; | ||
flex: 1; | ||
flex-wrap: wrap; | ||
gap: 0.625rem; | ||
align-items: center; | ||
justify-content: space-around; | ||
|
||
@media (max-width: 50rem) and (min-width: 31.35rem) { | ||
display: grid; | ||
grid-template-columns: 1fr 1fr; | ||
} | ||
} | ||
|
||
.big-text { | ||
.text { | ||
font: var(--tui-font-heading-6); | ||
margin-top: auto; | ||
margin-bottom: auto; | ||
} | ||
|
||
.button { | ||
.buttonCard { | ||
max-width: max-content; | ||
padding-right: 1.75rem; | ||
gap: 1rem; | ||
} | ||
|
||
@media (max-width: 50rem) { | ||
.button { | ||
@media (max-width: 50rem) { | ||
width: 100%; | ||
max-width: 100%; | ||
} | ||
} | ||
|
||
@media (max-width: 31.25rem) { | ||
.button { | ||
width: calc(100vw - 3rem - 2.5rem); | ||
max-width: calc(100vw - 3rem - 2.5rem); | ||
@media (max-width: 31.25rem) { | ||
width: calc(100vw - 5.5rem); | ||
max-width: calc(100vw - 5.5rem); | ||
flex-shrink: 0; | ||
} | ||
} | ||
|
||
:host { | ||
display: flex; | ||
flex: 1; | ||
flex-wrap: wrap; | ||
gap: 0.625rem; | ||
align-items: center; | ||
justify-content: space-around; | ||
} | ||
|
||
.Last { | ||
.LastCard { | ||
grid-column-end: 3; | ||
grid-column-start: 1; | ||
} | ||
|
||
@media (max-width: 50rem) { | ||
:host { | ||
display: grid; | ||
grid-template-columns: 1fr 1fr; | ||
} | ||
} | ||
|
||
@media (max-width: 31.25rem) { | ||
:host { | ||
display: flex; | ||
} | ||
|
||
.grow2 { | ||
width: 100%; | ||
height: 100%; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 21 additions & 0 deletions
21
apps/taiga-lumbermill/src/dashboards/iot/components/control-panel/control-panel.service.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import {Injectable} from '@angular/core'; | ||
|
||
interface ControlPanelData { | ||
readonly name: string; | ||
readonly img: string; | ||
} | ||
|
||
export const INITIAL_DATA: ControlPanelData[] = [ | ||
{name: 'Open the door', img: '@tui.door-open'}, | ||
{name: 'Play music', img: '@tui.speaker'}, | ||
{name: 'Call security', img: '@tui.shield-alert'}, | ||
{name: 'Turn up the heat', img: '@tui.heater'}, | ||
{name: 'Turn on the kettle', img: '@tui.coffee'}, | ||
]; | ||
|
||
@Injectable({ | ||
providedIn: 'root', | ||
}) | ||
export class ControlPanelService { | ||
public readonly controlPanelData = INITIAL_DATA; | ||
} |
14 changes: 0 additions & 14 deletions
14
apps/taiga-lumbermill/src/dashboards/iot/data/services/control-panel.service.ts
This file was deleted.
Oops, something went wrong.