-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(promo-rules): add rules for the included promos
- Loading branch information
1 parent
a410205
commit 3c307f3
Showing
15 changed files
with
407 additions
and
101 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
32 changes: 32 additions & 0 deletions
32
src/components/app-collapsible-section/app-collapsible-section.scss
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,32 @@ | ||
:host { | ||
display: block; | ||
} | ||
|
||
:host[hidden] { | ||
display: none; | ||
} | ||
|
||
header { | ||
cursor: pointer; | ||
|
||
&:before { | ||
float: left; | ||
margin-right: 0.5rem; | ||
} | ||
} | ||
|
||
section.collapsed { | ||
header:before { | ||
content: '▲'; | ||
} | ||
|
||
.body { | ||
display: none; | ||
} | ||
} | ||
|
||
section.expanded { | ||
header:before { | ||
content: '▼'; | ||
} | ||
} |
31 changes: 31 additions & 0 deletions
31
src/components/app-collapsible-section/app-collapsible-section.tsx
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,31 @@ | ||
import { Component, State } from '@stencil/core'; | ||
|
||
@Component({ | ||
tag: 'app-collapsible-section', | ||
styleUrl: 'app-collapsible-section.scss', | ||
shadow: true, | ||
}) | ||
export class AppHome { | ||
@State() private expanded = false; | ||
|
||
public render() { | ||
return ( | ||
<section | ||
class={` | ||
${this.expanded ? 'expanded' : 'collapsed'} | ||
`} | ||
> | ||
<header | ||
onClick={() => { | ||
this.expanded = !this.expanded; | ||
}} | ||
> | ||
<slot name="header" /> | ||
</header> | ||
<div class="body"> | ||
<slot /> | ||
</div> | ||
</section> | ||
); | ||
} | ||
} |
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
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
Oops, something went wrong.