Skip to content
This repository has been archived by the owner on Sep 26, 2022. It is now read-only.

Commit

Permalink
feat(overlay): adding transition, inOpts, outOpts as props
Browse files Browse the repository at this point in the history
  • Loading branch information
lloyet committed Nov 17, 2020
1 parent 7cef40a commit 85daff7
Show file tree
Hide file tree
Showing 3 changed files with 48 additions and 17 deletions.
2 changes: 1 addition & 1 deletion packages/api-generator/dist/index.js

Large diffs are not rendered by default.

56 changes: 42 additions & 14 deletions packages/api-generator/src/Overlay.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,48 @@
"version": 3,
"name": "Overlay",
"data": [
{
"visibility": "public",
"description": null,
"keywords": [],
"name": "transition",
"kind": "let",
"static": false,
"readonly": false,
"type": {
"kind": "type",
"text": "any",
"type": "any"
}
},
{
"visibility": "public",
"description": null,
"keywords": [],
"name": "inOpts",
"kind": "let",
"static": false,
"readonly": false,
"type": {
"kind": "type",
"text": "any",
"type": "any"
}
},
{
"visibility": "public",
"description": null,
"keywords": [],
"name": "outOpts",
"kind": "let",
"static": false,
"readonly": false,
"type": {
"kind": "type",
"text": "any",
"type": "any"
}
},
{
"visibility": "public",
"description": null,
Expand Down Expand Up @@ -77,20 +119,6 @@
},
"defaultValue": false
},
{
"visibility": "public",
"description": null,
"keywords": [],
"name": "fadeOptions",
"kind": "let",
"static": false,
"readonly": false,
"type": {
"kind": "type",
"text": "any",
"type": "any"
}
},
{
"visibility": "public",
"description": null,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,14 @@
import BackgroundColor from '../../internal/BackgroundColor';
let klass = '';
export let transition = fade;
export let inOpts = { duration: 250 };
export let outOpts = { duration: 250 };
export let active = true;
export let opacity = 0.46;
export let color = 'rgb(33, 33, 33)';
export let index = 5;
export let absolute = false;
export let fadeOptions = {};
export let style = '';
export { klass as class };
</script>
Expand All @@ -18,7 +20,8 @@

{#if active}
<div
transition:fade={fadeOptions}
in:transition={inOpts}
out:transition={outOpts}
class="s-overlay {klass}"
class:absolute
on:click
Expand Down

0 comments on commit 85daff7

Please sign in to comment.