Skip to content

Commit

Permalink
Merge pull request #60 from vaadin/icon-size
Browse files Browse the repository at this point in the history
Use the `--valo-icon-size` property
  • Loading branch information
web-padawan authored Dec 20, 2017
2 parents d31f084 + c97ed13 commit 33f1343
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 13 deletions.
2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"polymer": "^2.0.0",
"vaadin-control-state-mixin": "vaadin/vaadin-control-state-mixin#^2.0.0",
"vaadin-themable-mixin": "^1.1.0",
"vaadin-valo-theme": "^2.0.0",
"vaadin-valo-styles": "vaadin/vaadin-valo-styles#^2.0.0",
"vaadin-element-mixin": "vaadin/vaadin-element-mixin#^1.0.1"
}
}
2 changes: 1 addition & 1 deletion demo/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
<link rel="import" href="button-demo.html">

<link rel="import" href="../vaadin-button.html">
<link rel="import" href="../../vaadin-valo-theme/icons.html">
<link rel="import" href="../../vaadin-valo-styles/icons.html">

<vaadin-component-demo config-src="demos.json"></vaadin-component-demo>
</body>
Expand Down
2 changes: 1 addition & 1 deletion test/visual/valo.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<!doctype html>
<script src="../../../webcomponentsjs/webcomponents-loader.js"></script>
<link rel="import" href="../../vaadin-button.html">
<link rel="import" href="../../../vaadin-valo-theme/icons.html">
<link rel="import" href="../../../vaadin-valo-styles/icons.html">

<custom-style>
<style include="valo-typography valo-color">
Expand Down
20 changes: 10 additions & 10 deletions theme/valo/vaadin-button.html
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
<link rel="import" href="../../src/vaadin-button.html">

<link rel="import" href="../../../vaadin-valo-theme/color.html">
<link rel="import" href="../../../vaadin-valo-theme/sizing.html">
<link rel="import" href="../../../vaadin-valo-theme/spacing.html">
<link rel="import" href="../../../vaadin-valo-theme/style.html">
<link rel="import" href="../../../vaadin-valo-theme/typography.html">
<link rel="import" href="../../../vaadin-valo-styles/color.html">
<link rel="import" href="../../../vaadin-valo-styles/sizing.html">
<link rel="import" href="../../../vaadin-valo-styles/spacing.html">
<link rel="import" href="../../../vaadin-valo-styles/style.html">
<link rel="import" href="../../../vaadin-valo-styles/typography.html">

<dom-module id="valo-button" theme-for="vaadin-button">
<template>
Expand Down Expand Up @@ -239,15 +239,15 @@
<style>
:host ::slotted(iron-icon) {
display: inline-block;
width: 1.5em;
height: 1.5em;
width: var(--valo-icon-size);
height: var(--valo-icon-size);
}

/* Vaadin icons are based on a 16x16 grid (unlike Valo and Material icons with 24x24), so they look too big by default */
:host ::slotted(iron-icon[icon^="vaadin:"]) {
width: 1em;
height: 1em;
padding: 4px;
width: calc(var(--valo-icon-size) - 0.5em);
height: calc(var(--valo-icon-size) - 0.5em);
padding: 0.25em;
}

[part="prefix"] {
Expand Down

0 comments on commit 33f1343

Please sign in to comment.