Skip to content
This repository has been archived by the owner on Jan 16, 2018. It is now read-only.

Commit

Permalink
Merge fcd6cff into 64d1fe6
Browse files Browse the repository at this point in the history
  • Loading branch information
carloslancha committed Dec 12, 2017
2 parents 64d1fe6 + fcd6cff commit 5056e16
Show file tree
Hide file tree
Showing 50 changed files with 704 additions and 365 deletions.
8 changes: 3 additions & 5 deletions packages/clay-alert/src/ClayAlertBase.soy
Original file line number Diff line number Diff line change
Expand Up @@ -84,11 +84,9 @@
{param ariaLabel: 'Close' /}
{param elementClasses: 'close' /}
{param events: [ 'click': $handleCloseClick_ ] /}
{param icon: [
'alignment': 'right',
'spritemap': $spritemap,
'symbol': 'times'
] /}
{param icon: 'times' /}
{param iconAlignment: 'right' /}
{param spritemap: $spritemap /}
{param style: 'unstyled' /}
{param type: 'button' /}
{/call}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ exports[`ClayAlert should render a "danger" style alert 1`] = `
<div class="alert alert-danger fade show" role="alert">
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-exclamation-full">
<title>exclamation-full</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#exclamation-full"></use>
</svg>
</span>
Expand All @@ -14,6 +15,7 @@ exports[`ClayAlert should render a "success" style alert 1`] = `
<div class="alert alert-success fade show" role="alert">
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-check-circle-full">
<title>check-circle-full</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#check-circle-full"></use>
</svg>
</span>
Expand All @@ -24,6 +26,7 @@ exports[`ClayAlert should render a "warning" style alert 1`] = `
<div class="alert alert-warning fade show" role="alert">
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-warning-full">
<title>warning-full</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#warning-full"></use>
</svg>
</span>
Expand All @@ -34,11 +37,13 @@ exports[`ClayAlert should render a closeable alert 1`] = `
<div class="alert alert-warning fade alert-dismissible show" role="alert">
<button class="btn close btn-unstyled" aria-label="Close" type="button">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-times">
<title>times</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#times"></use>
</svg>
</button>
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-warning-full">
<title>warning-full</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#warning-full"></use>
</svg>
</span>
Expand All @@ -49,6 +54,7 @@ exports[`ClayAlert should render an "info" style alert 1`] = `
<div class="alert alert-info fade show" role="alert">
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-info-circle">
<title>info-circle</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#info-circle"></use>
</svg>
</span>
Expand All @@ -59,6 +65,7 @@ exports[`ClayAlert should render an alert with classes 1`] = `
<div class="alert alert-info fade my-custom-class show" role="alert">
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-info-circle">
<title>info-circle</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#info-circle"></use>
</svg>
</span>
Expand All @@ -69,6 +76,7 @@ exports[`ClayAlert should render an alert with id 1`] = `
<div class="alert alert-info fade show" id="myId" role="alert">
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-info-circle">
<title>info-circle</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#info-circle"></use>
</svg>
</span>
Expand All @@ -79,6 +87,7 @@ exports[`ClayAlert should render default markup 1`] = `
<div class="alert alert-info fade show" role="alert">
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-info-circle">
<title>info-circle</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#info-circle"></use>
</svg>
</span>
Expand Down
14 changes: 14 additions & 0 deletions packages/clay-alert/src/__tests__/__snapshots__/ClayStripe.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,13 @@ exports[`ClayStripe should render a "danger" style stripe 1`] = `
<div class="container">
<button class="btn close btn-unstyled" aria-label="Close" type="button">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-times">
<title>times</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#times"></use>
</svg>
</button>
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-exclamation-full">
<title>exclamation-full</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#exclamation-full"></use>
</svg>
</span>
Expand All @@ -22,11 +24,13 @@ exports[`ClayStripe should render a "success" style stripe 1`] = `
<div class="container">
<button class="btn close btn-unstyled" aria-label="Close" type="button">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-times">
<title>times</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#times"></use>
</svg>
</button>
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-check-circle-full">
<title>check-circle-full</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#check-circle-full"></use>
</svg>
</span>
Expand All @@ -39,11 +43,13 @@ exports[`ClayStripe should render a "warning" style stripe 1`] = `
<div class="container">
<button class="btn close btn-unstyled" aria-label="Close" type="button">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-times">
<title>times</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#times"></use>
</svg>
</button>
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-warning-full">
<title>warning-full</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#warning-full"></use>
</svg>
</span>
Expand All @@ -56,11 +62,13 @@ exports[`ClayStripe should render an "info" style stripe 1`] = `
<div class="container">
<button class="btn close btn-unstyled" aria-label="Close" type="button">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-times">
<title>times</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#times"></use>
</svg>
</button>
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-info-circle">
<title>info-circle</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#info-circle"></use>
</svg>
</span>
Expand All @@ -73,11 +81,13 @@ exports[`ClayStripe should render an stripe with classes 1`] = `
<div class="container">
<button class="btn close btn-unstyled" aria-label="Close" type="button">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-times">
<title>times</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#times"></use>
</svg>
</button>
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-info-circle">
<title>info-circle</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#info-circle"></use>
</svg>
</span>
Expand All @@ -90,11 +100,13 @@ exports[`ClayStripe should render an stripe with id 1`] = `
<div class="container">
<button class="btn close btn-unstyled" aria-label="Close" type="button">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-times">
<title>times</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#times"></use>
</svg>
</button>
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-info-circle">
<title>info-circle</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#info-circle"></use>
</svg>
</span>
Expand All @@ -107,11 +119,13 @@ exports[`ClayStripe should render default markup 1`] = `
<div class="container">
<button class="btn close btn-unstyled" aria-label="Close" type="button">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-times">
<title>times</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#times"></use>
</svg>
</button>
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-info-circle">
<title>info-circle</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#info-circle"></use>
</svg>
</span>
Expand Down
14 changes: 14 additions & 0 deletions packages/clay-alert/src/__tests__/__snapshots__/ClayToast.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,13 @@ exports[`ClayToast should render a "danger" style toast 1`] = `
<div class="alert alert-danger fade alert-dismissible show" role="alert">
<button class="btn close btn-unstyled" aria-label="Close" type="button">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-times">
<title>times</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#times"></use>
</svg>
</button>
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-exclamation-full">
<title>exclamation-full</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#exclamation-full"></use>
</svg>
</span>
Expand All @@ -19,11 +21,13 @@ exports[`ClayToast should render a "success" style toast 1`] = `
<div class="alert alert-success fade alert-dismissible show" role="alert">
<button class="btn close btn-unstyled" aria-label="Close" type="button">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-times">
<title>times</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#times"></use>
</svg>
</button>
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-check-circle-full">
<title>check-circle-full</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#check-circle-full"></use>
</svg>
</span>
Expand All @@ -34,11 +38,13 @@ exports[`ClayToast should render a "warning" style toast 1`] = `
<div class="alert alert-warning fade alert-dismissible show" role="alert">
<button class="btn close btn-unstyled" aria-label="Close" type="button">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-times">
<title>times</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#times"></use>
</svg>
</button>
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-warning-full">
<title>warning-full</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#warning-full"></use>
</svg>
</span>
Expand All @@ -49,11 +55,13 @@ exports[`ClayToast should render an "info" style toast 1`] = `
<div class="alert alert-info fade alert-dismissible show" role="alert">
<button class="btn close btn-unstyled" aria-label="Close" type="button">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-times">
<title>times</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#times"></use>
</svg>
</button>
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-info-circle">
<title>info-circle</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#info-circle"></use>
</svg>
</span>
Expand All @@ -64,11 +72,13 @@ exports[`ClayToast should render an toast with classes 1`] = `
<div class="alert alert-info fade alert-dismissible my-custom-class show" role="alert">
<button class="btn close btn-unstyled" aria-label="Close" type="button">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-times">
<title>times</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#times"></use>
</svg>
</button>
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-info-circle">
<title>info-circle</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#info-circle"></use>
</svg>
</span>
Expand All @@ -79,11 +89,13 @@ exports[`ClayToast should render an toast with id 1`] = `
<div class="alert alert-info fade alert-dismissible show" id="myId" role="alert">
<button class="btn close btn-unstyled" aria-label="Close" type="button">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-times">
<title>times</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#times"></use>
</svg>
</button>
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-info-circle">
<title>info-circle</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#info-circle"></use>
</svg>
</span>
Expand All @@ -94,11 +106,13 @@ exports[`ClayToast should render default markup 1`] = `
<div class="alert alert-info fade alert-dismissible show" role="alert">
<button class="btn close btn-unstyled" aria-label="Close" type="button">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-times">
<title>times</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#times"></use>
</svg>
</button>
<span class="alert-indicator">
<svg aria-hidden="true" class="lexicon-icon lexicon-icon-info-circle">
<title>info-circle</title>
<use xlink:href="../node_modules/lexicon-ux/build/images/icons/icons.svg#info-circle"></use>
</svg>
</span>
Expand Down
19 changes: 0 additions & 19 deletions packages/clay-badge/demos/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,6 @@ <h4>Badges default with WebComponents</h4>
<clay-badge label='"56"' style="info"></clay-badge>
<clay-badge label='"87"' style="warning"></clay-badge>
<clay-badge label='"999"' style="danger"></clay-badge>
<clay-badge label='"600"' style="light"></clay-badge>
<clay-badge label='"800"' style="dark"></clay-badge>
</div>
</div>

Expand Down Expand Up @@ -94,23 +92,6 @@ <h4>Badges default with WebComponents</h4>
},
'#styles-block'
);

new metal.ClayBadge(
{
label: '600',
style: 'light'
},
'#styles-block'
);

new metal.ClayBadge(
{
label: '800',
style: 'dark'
},
'#styles-block'
);

</script>
</body>
</html>
2 changes: 0 additions & 2 deletions packages/clay-badge/src/ClayBadge.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,7 @@ ClayBadge.STATE = {
*/
style: Config.oneOf([
'danger',
'dark',
'info',
'light',
'primary',
'secondary',
'success',
Expand Down
18 changes: 0 additions & 18 deletions packages/clay-badge/src/__tests__/ClayBadge.js
Original file line number Diff line number Diff line change
Expand Up @@ -104,22 +104,4 @@ describe('ClayBadge', function() {

expect(badge).toMatchSnapshot();
});

it('should render a `light color` badge', () => {
badge = new ClayBadge({
label: 'Foo',
style: 'light',
});

expect(badge).toMatchSnapshot();
});

it('should render a `dark color` badge', () => {
badge = new ClayBadge({
label: 'Foo',
style: 'dark',
});

expect(badge).toMatchSnapshot();
});
});
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,10 @@

exports[`ClayBadge should render a \`danger color\` badge 1`] = `<span class="badge badge-danger">Foo</span>`;

exports[`ClayBadge should render a \`dark color\` badge 1`] = `<span class="badge badge-dark">Foo</span>`;

exports[`ClayBadge should render a \`default color\` badge 1`] = `<span class="badge badge-primary">Foo</span>`;

exports[`ClayBadge should render a \`info color\` badge 1`] = `<span class="badge badge-info">Foo</span>`;

exports[`ClayBadge should render a \`light color\` badge 1`] = `<span class="badge badge-light">Foo</span>`;

exports[`ClayBadge should render a \`primary color\` badge 1`] = `<span class="badge badge-primary">Foo</span>`;

exports[`ClayBadge should render a \`secondary color\` badge 1`] = `<span class="badge badge-secondary">Foo</span>`;
Expand Down
Loading

0 comments on commit 5056e16

Please sign in to comment.