diff --git a/src/app/layouts/avatar/avatar-overview/avatar-overview.component.html b/src/app/layouts/avatar/avatar-overview/avatar-overview.component.html index e4b1ef8ff..9f7dd3a84 100644 --- a/src/app/layouts/avatar/avatar-overview/avatar-overview.component.html +++ b/src/app/layouts/avatar/avatar-overview/avatar-overview.component.html @@ -1,56 +1,51 @@ -
+ + + + + + + + + + + +
+ + - - - - - - - - - - - - - - - - - - + + + +
+ diff --git a/src/app/layouts/avatar/avatar-overview/avatar-overview.component.scss b/src/app/layouts/avatar/avatar-overview/avatar-overview.component.scss index fbf75d273..6ee88140a 100644 --- a/src/app/layouts/avatar/avatar-overview/avatar-overview.component.scss +++ b/src/app/layouts/avatar/avatar-overview/avatar-overview.component.scss @@ -1,47 +1,40 @@ -.avatar-overview-sample { +@use "igniteui-theming/sass/typography" as *; + +:host { display: flex; + flex-wrap: wrap; align-items: center; justify-content: center; - gap: 90px; - width: 100%; - min-height: 100vh; + gap: rem(100px); + height: 100vh; + padding: rem(32px); } -.avatar-with-badge { - position: relative; - display: inline-flex; +.profile-status { + anchor-name: --profile-status; } -.avatar-status { +.status-badge { position: absolute; - right: 6px; - bottom: 6px; + position-anchor: --profile-status; + inset-block-start: anchor(85%); + inset-inline-start: anchor(85%); + translate: -50% -50%; } .avatar-stack { - display: inline-flex; - align-items: center; -} - -.avatar-stack .size-large { - margin-left: -24px; -} + display: flex; -.avatar-stack .size-large:first-child { - margin-left: 0; -} + igx-avatar { + box-shadow: 0 0 0 rem(6px) var(--ig-surface-500); -.avatar-stack .igx-avatar { - border: 4px solid #fff; - box-sizing: border-box; -} - -.avatar-stack .size-large:last-child { - --ig-avatar-background: #e8eef6; - --ig-avatar-color: #6f8097; -} + + igx-avatar { + margin-inline-start: rem(-24px); + } -.avatar-stack .size-large:last-child .igx-avatar__initials { - font-size: 32px; - font-weight: 500; + &:last-child { + --ig-avatar-background: #e8eef6; + --ig-avatar-color: #6f8097; + } + } } diff --git a/src/app/layouts/avatar/avatar-shape/avatar-shape.component.html b/src/app/layouts/avatar/avatar-shape/avatar-shape.component.html index 88c355153..261085c24 100644 --- a/src/app/layouts/avatar/avatar-shape/avatar-shape.component.html +++ b/src/app/layouts/avatar/avatar-shape/avatar-shape.component.html @@ -1,56 +1,42 @@ -
-
- - - - - - - Circle -
+ + + + + +Circle -
- - - - - - 2 - - - Square -
+ + + + + + 2 + +Square -
- - - - - - - - Rounded -
-
+ + + + + + +Rounded diff --git a/src/app/layouts/avatar/avatar-shape/avatar-shape.component.scss b/src/app/layouts/avatar/avatar-shape/avatar-shape.component.scss index 78ac1f205..a6a47666f 100644 --- a/src/app/layouts/avatar/avatar-shape/avatar-shape.component.scss +++ b/src/app/layouts/avatar/avatar-shape/avatar-shape.component.scss @@ -1,48 +1,52 @@ -.avatar-shape-sample { - display: flex; - align-items: center; - justify-content: center; - gap: 90px; - min-height: 100vh; +@use "sass:list"; +@use "igniteui-theming/sass/typography" as *; + +$avatars: circle, square, rounded; + +:host { + display: grid; + grid-auto-flow: column; + grid-template-rows: auto auto; + place-content: center; + place-items: center; + column-gap: rem(40px); + row-gap: rem(8px); + height: 100vh; + padding: rem(32px); } -.avatar-variant { - display: inline-flex; - flex-direction: column; - align-items: center; - gap: 8px; +igx-avatar { + grid-row: 1; } -.avatar-label { +span { + grid-row: 2; + text-align: center; color: var(--ig-gray-600); - font-size: 0.875rem; - line-height: 1.25rem; -} -.avatar-with-badge { - position: relative; - display: inline-flex; + @include type-style("body-1") { + margin: 0; + }; } -.avatar-status { - --size: 18px; +igx-badge { + --ig-size: var(--ig-size-small); + position: absolute; - right: -4px; - bottom: -4px; - font-size: 0.75rem; - line-height: 1; + inset-block-start: anchor(85.5%); + inset-inline-start: anchor(85.5%); + translate: -50% -50%; } -.avatar-dot-badge { - --size: 12px; - right: 3px; - bottom: 3px; -} +// The avatars and badges are flat siblings, so every badge needs its own anchor name to pin to. +@each $avatar in $avatars { + $i: list.index($avatars, $avatar); -.avatar-count-badge { - --ig-badge-text-color: #ffffff; -} + igx-avatar:nth-of-type(#{$i}) { + anchor-name: --#{$avatar}; + } -.avatar-check-badge { - --ig-badge-icon-color: #ffffff; + igx-badge:nth-of-type(#{$i}) { + position-anchor: --#{$avatar}; + } } diff --git a/src/app/layouts/avatar/avatar-size/avatar-size.component.html b/src/app/layouts/avatar/avatar-size/avatar-size.component.html index 5b16e53d1..be7a2c62b 100644 --- a/src/app/layouts/avatar/avatar-size/avatar-size.component.html +++ b/src/app/layouts/avatar/avatar-size/avatar-size.component.html @@ -1,61 +1,41 @@ -
-
- - - - - - - - - Large -
+ + + + + +Large -
- - - - - - - - - Medium -
+ + + + + +Medium -
- - - - - - - - - Small -
-
+ + + + + +Small diff --git a/src/app/layouts/avatar/avatar-size/avatar-size.component.scss b/src/app/layouts/avatar/avatar-size/avatar-size.component.scss index 5d2dcdb74..79f4204bb 100644 --- a/src/app/layouts/avatar/avatar-size/avatar-size.component.scss +++ b/src/app/layouts/avatar/avatar-size/avatar-size.component.scss @@ -1,69 +1,51 @@ -.avatar-size-sample { - display: flex; - align-items: center; - justify-content: center; - gap: 90px; - min-height: 100vh; -} - -.avatar-size { - display: inline-flex; - flex-direction: column; - align-items: center; - gap: 8px; -} +@use "sass:list"; +@use "igniteui-theming/sass/typography" as *; -.avatar-frame { - display: inline-flex; - align-items: center; - justify-content: center; +:host { + display: grid; + grid-auto-flow: column; + grid-template-rows: auto auto; + place-content: center; + place-items: center; + column-gap: rem(48px); + row-gap: rem(8px); + height: 100vh; + padding: rem(32px); } -.avatar-frame-large { - width: 72px; - height: 72px; +igx-avatar { + grid-row: 1; } -.avatar-frame-medium { - width: 72px; - height: 72px; -} - -.avatar-frame-small { - width: 72px; - height: 72px; -} - -.avatar-label { +span { + grid-row: 2; + text-align: center; color: var(--ig-gray-600); - font-size: 0.875rem; - line-height: 1.25rem; -} -.avatar-with-badge { - position: relative; - display: inline-flex; + @include type-style("body-1") { + margin: 0; + }; } -.avatar-status { +igx-badge { position: absolute; - line-height: 1; + inset-block-start: anchor(85.5%); + inset-inline-start: anchor(85.5%); + translate: -50% -50%; } -.avatar-dot-badge-large { - --size: 16px; - right: 3px; - bottom: 3px; -} +$avatars: large, medium, small; -.avatar-dot-badge-medium { - --size: 14px; - right: 2px; - bottom: 2px; -} +// The avatars and badges are flat siblings, so every badge needs its own anchor name to pin to. +@each $avatar in $avatars { + $i: list.index($avatars, $avatar); + + igx-avatar:nth-of-type(#{$i}) { + anchor-name: --#{$avatar}; + } -.avatar-dot-badge-small { - --size: 12px; - right: 1px; - bottom: 1px; + igx-badge:nth-of-type(#{$i}) { + --ig-size: var(--ig-size-#{$avatar}); + position-anchor: --#{$avatar}; + } } diff --git a/src/app/layouts/avatar/avatar-styling/avatar-styling.component.html b/src/app/layouts/avatar/avatar-styling/avatar-styling.component.html index 07510f6c3..758148130 100644 --- a/src/app/layouts/avatar/avatar-styling/avatar-styling.component.html +++ b/src/app/layouts/avatar/avatar-styling/avatar-styling.component.html @@ -1,71 +1,67 @@ -
- - Chats + + Chats - -
- - - - - -
-

Nick Evans

- Hi Samira, thanks for the ... - 9:44 AM -
+ +
+ + + + + +
+

Nick Evans

+ Hi Samira, thanks for the ... + 9:44 AM +
- -
- - - - -
-

James Ford

- I'll send the text and im ... - 8:30 AM -
+ +
+ + + + +
+

James Ford

+ I'll send the text and im ... + 8:30 AM +
- -
- - - - - -
-

Kate Porter

- That's great! - Yesterday -
+ +
+ + + + + +
+

Kate Porter

+ That's great! + Yesterday +
- Meetings + Meetings - - - - -

Weekly Meeting

- https://www.infra.com - Monday -
+ + + + +

Weekly Meeting

+ https://www.infra.com + Monday +
- - - - -

Design Discussion

- https://www.infra.com - 11:30 AM -
-
-
+ + + + +

Design Discussion

+ https://www.infra.com + 11:30 AM +
+ diff --git a/src/app/layouts/avatar/avatar-styling/avatar-styling.component.scss b/src/app/layouts/avatar/avatar-styling/avatar-styling.component.scss index 13d20bb3f..e4e2886f9 100644 --- a/src/app/layouts/avatar/avatar-styling/avatar-styling.component.scss +++ b/src/app/layouts/avatar/avatar-styling/avatar-styling.component.scss @@ -1,35 +1,40 @@ -.avatar-styling-sample { +@use "igniteui-theming/sass/typography" as *; + +:host { display: flex; align-items: center; justify-content: center; + height: 100vh; } -.chat-list { - width: 344px; - max-width: 100%; +igx-list { + --ig-list-border-width: #{rem(1px)}; + --ig-list-border-color: var(--ig-gray-300); + --ig-list-header-text-color: var(--ig-gray-900); + + max-width: rem(328px); } -.size-small { - --ig-size: var(--ig-size-small); +igx-avatar { + --ig-avatar-background: var(--ig-gray-300); + --ig-avatar-color: var(--ig-gray-300-contrast); } .avatar-with-badge { position: relative; - display: inline-flex; +} + +igx-badge { + --ig-size: var(--ig-size-small); } .avatar-status { - --ig-badge-icon-color: #ffffff; position: absolute; - right: -4px; - bottom: -4px; + inset-inline-end: rem(-4px); + inset-block-end: rem(-4px); } .avatar-muted-badge { --ig-badge-background-color: var(--ig-gray-300); - --ig-badge-icon-color: var(--ig-gray-700); -} - -.avatar-muted { - --ig-avatar-background: #D2DBE8; + --ig-badge-icon-color: var(--ig-gray-300-contrast); } diff --git a/src/app/layouts/avatar/avatar-styling/layout.scss b/src/app/layouts/avatar/avatar-styling/layout.scss deleted file mode 100644 index d3a420849..000000000 --- a/src/app/layouts/avatar/avatar-styling/layout.scss +++ /dev/null @@ -1,4 +0,0 @@ -:host { - display: inline-flex; - gap: 32px -} diff --git a/src/app/layouts/avatar/avatar-tailwind-styling/avatar-tailwind-styling.component.html b/src/app/layouts/avatar/avatar-tailwind-styling/avatar-tailwind-styling.component.html index 79cd59492..d4fff12c1 100644 --- a/src/app/layouts/avatar/avatar-tailwind-styling/avatar-tailwind-styling.component.html +++ b/src/app/layouts/avatar/avatar-tailwind-styling/avatar-tailwind-styling.component.html @@ -1,111 +1,105 @@ -
- - - Cafe interior - + + + Cafe interior + + + + + Kate Thompson +

3D Artist. Turning polygons into worlds and immersive digital realities

- + + +
+ @for (stat of profileStats; track stat.label; let isLast = $last) { +
+ {{ stat.value }} + {{ stat.label }} +
+ @if (!isLast) { + + } + } +
+
+ + +
+ + + +
+
+
+ + + + - Kate Thompson - - - -

3D Artist. Turning polygons into worlds and immersive digital realities

-
- @for (stat of profileStats; track stat.label; let isLast = $last) { -
- {{ stat.value }} - {{ stat.label }} -
- @if (!isLast) { - - } + + Kate Thompson +

3D Artist. Turning polygons into worlds and immersive digital realities

+ + +
+ @for (stat of profileStats; track stat.label; let isLast = $last) { +
+ {{ stat.value }} + {{ stat.label }} +
+ @if (!isLast) { + } -
-
- - - -
- - - -
-
- - - - - - - + } +
+
+ + +
+ + -
- - - -
- - -
+ +
+ + + diff --git a/src/app/layouts/avatar/avatar-tailwind-styling/avatar-tailwind-styling.component.scss b/src/app/layouts/avatar/avatar-tailwind-styling/avatar-tailwind-styling.component.scss index 7f26ddcb5..ea7083981 100644 --- a/src/app/layouts/avatar/avatar-tailwind-styling/avatar-tailwind-styling.component.scss +++ b/src/app/layouts/avatar/avatar-tailwind-styling/avatar-tailwind-styling.component.scss @@ -1,3 +1,36 @@ +@use "igniteui-theming/sass/typography" as *; + :host { + display: grid; + grid-template-columns: repeat(auto-fit, rem(344px)); + gap: rem(40px); + place-content: center; + height: 100vh; +} + +igx-card:nth-of-type(2) { + align-self: center; +} + +.card-sample-custom-subtitle { display: block; + color: var(--ig-gray-700); + + @include type-style("body-2") { + margin-block-start: rem(8px); + }; +} + +.stats-title { + color: var(--ig-gray-900); + + @include type-style("subtitle-1") { + font-weight: 600; + }; +} + +.stats-subtitle { + color: var(--ig-gray-500); + + @include type-style("body-2"); } diff --git a/src/app/layouts/avatar/avatar-variants/avatar-variants.component.html b/src/app/layouts/avatar/avatar-variants/avatar-variants.component.html index 438406536..6ac275898 100644 --- a/src/app/layouts/avatar/avatar-variants/avatar-variants.component.html +++ b/src/app/layouts/avatar/avatar-variants/avatar-variants.component.html @@ -1,56 +1,44 @@ -
-
- - - - - - - Image -
+ + + + + +Image -
- - - - - - 2 - - - Icon -
+ + + + + + 2 + +Icon + + + + + + + +Initials -
- - - - - - - - Initials -
-
diff --git a/src/app/layouts/avatar/avatar-variants/avatar-variants.component.scss b/src/app/layouts/avatar/avatar-variants/avatar-variants.component.scss index 355ff7df2..a4c56b17f 100644 --- a/src/app/layouts/avatar/avatar-variants/avatar-variants.component.scss +++ b/src/app/layouts/avatar/avatar-variants/avatar-variants.component.scss @@ -1,48 +1,53 @@ -.avatar-variants-sample { - display: flex; - align-items: center; - justify-content: center; - gap: 90px; - min-height: 100vh; +@use "sass:list"; +@use "igniteui-theming/sass/typography" as *; + +$avatars: circle, square, rounded; + +:host { + display: grid; + grid-auto-flow: column; + grid-template-rows: auto auto; + place-content: center; + place-items: center; + column-gap: rem(48px); + row-gap: rem(8px); + height: 100vh; + padding: rem(32px); } -.avatar-variant { - display: inline-flex; - flex-direction: column; - align-items: center; - gap: 8px; +// :where() keeps the sample's own rules at zero +:where(igx-avatar) { + grid-row: 1; } -.avatar-label { +:where(span) { + grid-row: 2; + text-align: center; color: var(--ig-gray-600); - font-size: 0.875rem; - line-height: 1.25rem; -} -.avatar-with-badge { - position: relative; - display: inline-flex; + @include type-style("body-1") { + margin: 0; + }; } -.avatar-status { - --size: 18px; +:where(igx-badge) { + --ig-size: var(--ig-size-small); + position: absolute; - right: -4px; - bottom: -4px; - font-size: 0.75rem; - line-height: 1; + inset-block-start: anchor(85.5%); + inset-inline-start: anchor(85.5%); + translate: -50% -50%; } -.avatar-dot-badge { - --size: 12px; - right: 3px; - bottom: 3px; -} +// The avatars and badges are flat siblings, so every badge needs its own anchor name to pin to. +@each $avatar in $avatars { + $i: list.index($avatars, $avatar); -.avatar-count-badge { - --ig-badge-text-color: #ffffff; -} + igx-avatar:nth-of-type(#{$i}) { + anchor-name: --#{$avatar}; + } -.avatar-check-badge { - --ig-badge-icon-color: #ffffff; + igx-badge:nth-of-type(#{$i}) { + position-anchor: --#{$avatar}; + } }