Skip to content

Commit

Permalink
fix(note): viv-383 issue-619 fixing the safari 13 compliance (#620)
Browse files Browse the repository at this point in the history
* issue #619: fixing the sfari 13 compliance

* fixing PR remarks
  • Loading branch information
gullerya committed Jan 29, 2021
1 parent 45aeb4e commit 9a7224a
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 2 deletions.
10 changes: 8 additions & 2 deletions components/note/src/vwc-note.scss
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,21 @@
$connotations: success alert warning info announcement
);

$border-value: 8px solid var(#{color-semantic.$vvd-color-connotation});

:host {
padding: 20px;
display: flex;
align-items: stretch;
background-color: var(#{scheme-variables.$vvd-color-base});
color: var(#{scheme-variables.$vvd-color-on-base});
border-inline-start: 8px solid var(#{color-semantic.$vvd-color-connotation});
border-left: $border-value;
border-inline-start: $border-value;
border-radius: 6px;
box-shadow: inset 0 1px 0 0 #b3b3b3, inset -1px 0 0 0 #b3b3b3, inset 0 -1px 0 0 #b3b3b3;
box-shadow:
inset 0 1px 0 0 var(#{scheme-variables.$vvd-color-contrast-tinged}),
inset -1px 0 0 0 var(#{scheme-variables.$vvd-color-contrast-tinged}),
inset 0 -1px 0 0 var(#{scheme-variables.$vvd-color-contrast-tinged});
overflow: hidden;
contain: content;
}
Expand Down
11 changes: 11 additions & 0 deletions components/note/test/note.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,17 @@ describe('note', () => {
assertComputedStyle(note, { paddingBlockEnd: '20px' });
});

it('should have border appearing correct', async () => {
const [note] = addElement(
textToDomToParent(`<${COMPONENT_NAME}>Internal contents</${COMPONENT_NAME}>`)
);
await waitNextTask();
assertComputedStyle(note, {
boxShadow:
'rgb(179, 179, 179) 0px 1px 0px 0px inset, rgb(179, 179, 179) -1px 0px 0px 0px inset, rgb(179, 179, 179) 0px -1px 0px 0px inset',
});
});

describe('header', () => {
it('should have header when header is set', async () => {
const [note] = addElement(
Expand Down

0 comments on commit 9a7224a

Please sign in to comment.