@forter/button
Advanced tools
Comparing version 1.0.0-alpha.5 to 1.0.0-alpha.6
@@ -80,2 +80,6 @@ import { decorate as _decorate } from './_virtual/_rollupPluginBabelHelpers.js'; | ||
this.selection.hidden = true; | ||
const detail = this.clipboard; | ||
this.dispatchEvent(new CustomEvent('copy', { | ||
detail | ||
})); | ||
} | ||
@@ -82,0 +86,0 @@ }] |
{ | ||
"name": "@forter/button", | ||
"version": "1.0.0-alpha.5", | ||
"version": "1.0.0-alpha.6", | ||
"description": "Button from Forter Components", | ||
@@ -45,2 +45,3 @@ "main": "index.js", | ||
"devDependencies": { | ||
"crocks": "^0.11.1", | ||
"rollup": "^1.4.1", | ||
@@ -58,3 +59,3 @@ "rollup-plugin-babel": "^4.3.2", | ||
}, | ||
"gitHead": "922162e80565d1a5211c94043f0f90e5cb33ba65" | ||
"gitHead": "f85a341f66b657ab4742fd1f86d9b9798768f983" | ||
} |
@@ -43,3 +43,5 @@ import { LitElement, html, property, query } from 'lit-element'; | ||
this.selection.hidden = true; | ||
const detail = this.clipboard; | ||
this.dispatchEvent(new CustomEvent('copy', { detail })); | ||
} | ||
} |
import { html } from 'lit-html' | ||
import { storiesOf } from '@storybook/polymer'; | ||
import { withClassPropertiesKnobs } from '@open-wc/demoing-storybook'; | ||
import { withKnobs } from '@storybook/addon-knobs'; | ||
import { action } from '@storybook/addon-actions'; | ||
import compose from 'crocks/helpers/compose'; | ||
import propOr from 'crocks/helpers/propOr'; | ||
import '../src/fc-copy'; | ||
import { FcCopy } from '../src/FcCopy'; | ||
@@ -15,5 +17,8 @@ import markdown from '../fc-copy.md'; | ||
function elementProperties() { | ||
return withClassPropertiesKnobs(FcCopy, { template: html` | ||
<fc-copy clipboard="Copied to clipboard">Copy to Clipboard</fc-copy> | ||
`}); | ||
return html` | ||
<fc-copy | ||
clipboard="${text('Text to Copy', 'Copy to Clipboard')}" | ||
@copy="${compose(action('copy'), propOr(null, 'detail'))}" | ||
>${text('Slotted Content', 'Click to Copy')}</fc-copy> | ||
`; | ||
} | ||
@@ -20,0 +25,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
67731
1623
6