@sb1/ffe-icons 12.17.0 → 13.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (180) hide show
  1. package/README.md +3 -167
  2. package/bin/build.js +47 -59
  3. package/less/ffe-icons.less +2 -0
  4. package/less/icons.less +26 -0
  5. package/less/theme.less +14 -0
  6. package/package.json +33 -29
  7. package/CHANGELOG.md +0 -977
  8. package/dist/ffe-icons.svg +0 -10
  9. package/icons/atv-ikon.svg +0 -1
  10. package/icons/badekar-dusj-ikon.svg +0 -1
  11. package/icons/bamse-ikon.svg +0 -1
  12. package/icons/bankid-ikon.svg +0 -1
  13. package/icons/bat-liten-ikon.svg +0 -1
  14. package/icons/bat-stor-ikon.svg +0 -1
  15. package/icons/bestikk-ikon.svg +0 -1
  16. package/icons/beta-ikon.svg +0 -1
  17. package/icons/betaling-100-ikon.svg +0 -1
  18. package/icons/betaling-kontaktlos-ikon.svg +0 -1
  19. package/icons/betaling-kontaktlos-info-ikon.svg +0 -1
  20. package/icons/betalingskort-globus-ikon.svg +0 -1
  21. package/icons/betalingskort-hand-ikon.svg +0 -1
  22. package/icons/betalingskort-ikon.svg +0 -1
  23. package/icons/betalingskort-innpakket-ikon.svg +0 -1
  24. package/icons/betalingskort-kreditt-ikon.svg +0 -1
  25. package/icons/betalingskort-kryss-ikon.svg +0 -1
  26. package/icons/betalingskort-stjerne-ikon.svg +0 -1
  27. package/icons/bil-camping-ikon.svg +0 -1
  28. package/icons/bil-ikon.svg +0 -1
  29. package/icons/bil-pil-ikon.svg +0 -1
  30. package/icons/binders-ikon.svg +0 -1
  31. package/icons/blyant-ikon.svg +0 -1
  32. package/icons/boks-ikon.svg +0 -1
  33. package/icons/bsu-ikon.svg +0 -1
  34. package/icons/bygning-pluss-ikon.svg +0 -1
  35. package/icons/campingbil-ikon.svg +0 -1
  36. package/icons/campingvogn-ikon.svg +0 -1
  37. package/icons/chevron-ikon.svg +0 -1
  38. package/icons/dokument-avtalegiro-check-ikon.svg +0 -1
  39. package/icons/dokument-efaktura-ikon.svg +0 -1
  40. package/icons/dokument-hus-ikon.svg +0 -1
  41. package/icons/dokument-med-tekst-ikon.svg +0 -1
  42. package/icons/faks-printer-ikon.svg +0 -1
  43. package/icons/faks-printer-solid-ikon.svg +0 -1
  44. package/icons/familie-ikon.svg +0 -1
  45. package/icons/filter-ikon.svg +0 -3
  46. package/icons/flamme-ikon.svg +0 -1
  47. package/icons/fly-ikon.svg +0 -1
  48. package/icons/forstorrelsesglass-ikon-minus.svg +0 -1
  49. package/icons/forstorrelsesglass-ikon-pluss.svg +0 -1
  50. package/icons/forstorrelsesglass-ikon.svg +0 -1
  51. package/icons/fritidshus-ikon.svg +0 -1
  52. package/icons/gave-ikon.svg +0 -1
  53. package/icons/globe-ikon.svg +0 -1
  54. package/icons/graf-opp-enkel-ikon.svg +0 -1
  55. package/icons/graf-opp-ikon.svg +0 -1
  56. package/icons/gravemaskin-ikon.svg +0 -1
  57. package/icons/hake-ikon.svg +0 -1
  58. package/icons/hake-sirkel-ikon.svg +0 -1
  59. package/icons/hake-sirkel-solid-ikon.svg +0 -1
  60. package/icons/hake-stjerne-ikon.svg +0 -1
  61. package/icons/handlevogn-ikon.svg +0 -1
  62. package/icons/handlevogn-pakker-ikon.svg +0 -1
  63. package/icons/hengelas-ikon.svg +0 -1
  64. package/icons/hengelas-omriss-ikon.svg +0 -1
  65. package/icons/hjerte-ikon.svg +0 -1
  66. package/icons/hjerte-kardiograf-ikon.svg +0 -1
  67. package/icons/hus-enebolig-ikon.svg +0 -1
  68. package/icons/hus-hake-ikon.svg +0 -1
  69. package/icons/hus-hammer-ikon.svg +0 -1
  70. package/icons/hus-hjerte-ikon.svg +0 -1
  71. package/icons/hus-horisontaldelt-ikon.svg +0 -1
  72. package/icons/hus-ikon.svg +0 -1
  73. package/icons/hus-kjedet-ikon.svg +0 -1
  74. package/icons/hus-kr-ikon.svg +0 -1
  75. package/icons/hus-leilighet-ikon.svg +0 -1
  76. package/icons/hus-pil-opp-ikon.svg +0 -1
  77. package/icons/hus-pil-opp-ned-ikon.svg +0 -1
  78. package/icons/hus-pil-ut-ikon.svg +0 -1
  79. package/icons/hus-rekkehus-ikon.svg +0 -1
  80. package/icons/hus-stjerne-ikon.svg +0 -1
  81. package/icons/hus-tommer-ikon.svg +0 -1
  82. package/icons/hus-tre-ikon.svg +0 -1
  83. package/icons/hus-vertikaldelt-ikon.svg +0 -1
  84. package/icons/info-ikon.svg +0 -1
  85. package/icons/info-sirkel-ikon.svg +0 -1
  86. package/icons/info-sirkel-solid-ikon.svg +0 -1
  87. package/icons/kake-kvart-ikon.svg +0 -1
  88. package/icons/kakediagram-liten-bit-ikon.svg +0 -1
  89. package/icons/kalender-ikon.svg +0 -1
  90. package/icons/kalkulator-ikon.svg +0 -1
  91. package/icons/kartmarkor-ikon.svg +0 -1
  92. package/icons/katt-ikon.svg +0 -1
  93. package/icons/koffert-ikon.svg +0 -1
  94. package/icons/konfetti-ikon.svg +0 -1
  95. package/icons/kontorbygg-ikon.svg +0 -1
  96. package/icons/kontorbygg-solid-ikon.svg +0 -1
  97. package/icons/konvolutt-ikon.svg +0 -1
  98. package/icons/kopier-ikon.svg +0 -1
  99. package/icons/kr-armband-ikon.svg +0 -1
  100. package/icons/kr-hake-ikon.svg +0 -1
  101. package/icons/kr-klokke-ikon.svg +0 -1
  102. package/icons/kr-pil-ikon.svg +0 -1
  103. package/icons/kr-pil-solid-ikon.svg +0 -1
  104. package/icons/kr-pose-ikon.svg +0 -1
  105. package/icons/kr-sirkel-pil-ikon.svg +0 -1
  106. package/icons/kr-tannhjul-ikon.svg +0 -1
  107. package/icons/kryss-ikon.svg +0 -1
  108. package/icons/kryss-sirkel-ikon.svg +0 -1
  109. package/icons/kryss-sirkel-solid-ikon.svg +0 -1
  110. package/icons/laptop-ikon.svg +0 -1
  111. package/icons/lommebok-ikon.svg +0 -1
  112. package/icons/lys-mork-ikon.svg +0 -1
  113. package/icons/lyspare-ikon.svg +0 -1
  114. package/icons/mobil-a-b-c-ikon.svg +0 -1
  115. package/icons/mobil-ikon.svg +0 -1
  116. package/icons/mobil-snakkeboble-ikon.svg +0 -1
  117. package/icons/mobil-utropstegn-ikon.svg +0 -1
  118. package/icons/moped-ikon.svg +0 -1
  119. package/icons/motorsykkel-ikon.svg +0 -1
  120. package/icons/mynter-to-stabler-ikon.svg +0 -1
  121. package/icons/mynter-to-stabler-pluss-ikon.svg +0 -1
  122. package/icons/mynter-tre-stabler-ikon.svg +0 -1
  123. package/icons/nokkelhull-ikon.svg +0 -1
  124. package/icons/p-pose-ikon.svg +0 -1
  125. package/icons/p-pose-stjerne-ikon.svg +0 -1
  126. package/icons/paraply-ikon.svg +0 -1
  127. package/icons/pdf-ikon.svg +0 -1
  128. package/icons/person-brukket-arm-ikon.svg +0 -1
  129. package/icons/person-ikon.svg +0 -1
  130. package/icons/person-mikrofon-ikon.svg +0 -1
  131. package/icons/person-pluss-ikon.svg +0 -1
  132. package/icons/person-rullestol-ikon.svg +0 -1
  133. package/icons/person-slips-ikon.svg +0 -1
  134. package/icons/person-streker-ikon.svg +0 -1
  135. package/icons/personer-ikon.svg +0 -1
  136. package/icons/pil-ned-i-boks-ikon.svg +0 -1
  137. package/icons/pil-ned-ikon.svg +0 -1
  138. package/icons/pil-ut-av-boks-ikon.svg +0 -1
  139. package/icons/pil-ut-av-boks-skraa-ikon.svg +0 -1
  140. package/icons/piler-hoyre-venstre-ikon.svg +0 -1
  141. package/icons/plaster-ikon.svg +0 -1
  142. package/icons/pluss-ikon.svg +0 -1
  143. package/icons/pose-i-haand-ikon.svg +0 -1
  144. package/icons/pose-piler-hoyre-venstre-ikon.svg +0 -1
  145. package/icons/pose-trettien-ikon.svg +0 -1
  146. package/icons/robat-ikon.svg +0 -1
  147. package/icons/rundt-snakkeboble-ikon.svg +0 -1
  148. package/icons/seilbat-ikon.svg +0 -1
  149. package/icons/sirkel-1-2-3-ikon.svg +0 -1
  150. package/icons/skyskraper-ikon.svg +0 -1
  151. package/icons/snakkeboble-ikon.svg +0 -1
  152. package/icons/snoscooter-ikon.svg +0 -1
  153. package/icons/sofa-ikon.svg +0 -1
  154. package/icons/soppelkasse-ikon.svg +0 -1
  155. package/icons/soylediagram-ikon.svg +0 -1
  156. package/icons/soylediagram-med-pil-ikon.svg +0 -1
  157. package/icons/sparegris-ikon.svg +0 -1
  158. package/icons/spleis-ikon.svg +0 -1
  159. package/icons/sporsmalstegn-ikon.svg +0 -1
  160. package/icons/stetoskop-ikon.svg +0 -1
  161. package/icons/svar-pil-ikon.svg +0 -1
  162. package/icons/sykebil-ikon.svg +0 -1
  163. package/icons/tabell-kroner-ikon.svg +0 -1
  164. package/icons/taleassistent-ikon.svg +0 -1
  165. package/icons/tannhjul-ikon.svg +0 -1
  166. package/icons/tannhjul-solid-ikon.svg +0 -1
  167. package/icons/telefon-ikon.svg +0 -1
  168. package/icons/tommel-opp-ikon.svg +0 -1
  169. package/icons/traktor-ikon.svg +0 -1
  170. package/icons/tre-ikon.svg +0 -4
  171. package/icons/trillekoffert-ikon.svg +0 -1
  172. package/icons/understrek-1-2-3-ikon.svg +0 -1
  173. package/icons/ung-caps-ikon.svg +0 -1
  174. package/icons/ungdom-ikon.svg +0 -5
  175. package/icons/utropstegn-ikon.svg +0 -1
  176. package/icons/varebil-ikon.svg +0 -1
  177. package/icons/varsel-ikon.svg +0 -1
  178. package/icons/verktoy-skiftenokkel-ikon.svg +0 -1
  179. package/icons/widget-ikon.svg +0 -1
  180. package/icons/xls-ikon.svg +0 -1
package/README.md CHANGED
@@ -1,171 +1,7 @@
1
1
  # @sb1/ffe-icons
2
2
 
3
- This is a package meant for sharing commonly used icons between various projects. If your project uses a generic icon which might be useful for others, you should consider adding it here.
3
+ ## Deprecated package
4
4
 
5
- ffe-icons builds an SVG sprite with all the icons from `icons/` and puts it in the `dist/`folder.
5
+ This package is deprecated, and will be removed from the designsystem repo.
6
6
 
7
- **Note:** Previous icon requirements description has been moved from `icons/_ICON_REQUIREMENTS.MD` into the "[Adding a new icon](#adding-a-new-icon)" section within this document.
8
-
9
- ## Table of contents
10
-
11
- - [Install](#install)
12
- - [Usage](#usage)
13
- - [Using the ffe-icons sprite](#using-the-ffe-icons-sprite)
14
- - [Adding a new icon](#adding-a-new-icon)
15
- - [Optimizing](#optimizing)
16
- - [Naming](#naming)
17
- - [Adding](#adding)
18
- - [Useful resources](#useful-resources)
19
- - [Links](#links)
20
- - [Optimizing with Inkscape](#optimizing-with-inkscape)
21
- - [Know issues](#known-issues)
22
-
23
- ## Install
24
-
25
- ```bash
26
- npm install --save @sb1/ffe-icons
27
- ```
28
-
29
- ## Usage
30
-
31
- See also `@sb1/ffe-icons-react`.
32
-
33
- First add an `icons.json` file to your project where you define what icons you want. Additionally, you can
34
- pass in options that [svg-sprite](https://github.com/jkphl/svg-sprite) support to override defaults.
35
-
36
- Example `icons.json`:
37
-
38
- ```json
39
- {
40
- "dest": "app/",
41
- "icons": [
42
- "1-2-3-sirkel-ikon",
43
- "bamse-ikon",
44
- "dor-ikon",
45
- "flamme-ikon",
46
- "logo-sparebank1",
47
- "twitter-ikon"
48
- ],
49
- "config": {
50
- "log": "error",
51
- "mode": {
52
- "symbol": {
53
- "sprite": "awesome-icons.svg"
54
- }
55
- }
56
- }
57
- }
58
- ```
59
-
60
- To build your icon sprite, run the `ffe-icons` command using Node and pass the path to your `icons.json` as `--opts`.
61
- It is recommended you add an npm-script to your `package.json` like so:
62
-
63
- ```json
64
- {
65
- "name": "awesome-client",
66
- "scripts": {
67
- ...
68
- "ffe:icons": "ffe-icons --opts=icons.json",
69
- ...
70
- }
71
- }
72
- ```
73
-
74
- Then, in your terminal:
75
-
76
- `npm run ffe:icons`
77
-
78
- A fresh SVG sprite should now have arrived at your destination.
79
-
80
- Note: **it is recommended that you _not_ check the generated sprite into source control, but instead let ffe-icons
81
- generate it at build-time.** This reduces the number of manual build steps, and keeps you up-to-date.
82
-
83
- ### Using the ffe-icons sprite
84
-
85
- The primary color (royal blue) is removed from the SVG. This is so CSS can be used to override the color. To re-instate
86
- royal blue as the primary color, add the following to your global icon class:
87
-
88
- ```css
89
- .icon {
90
- fill: '#002776'; // Or, even better:
91
- fill: @ffe-blue-royal; // assuming use and import of ffe-core variables
92
-
93
- // To add alternatives, replace the fill attribute with whatever color you need
94
- &--white {
95
- fill: #fff;
96
- }
97
- &--black {
98
- fill: #000;
99
- }
100
- }
101
- ```
102
-
103
- Non-royal blue colors are left as-is, so details in other colors are left untouched.
104
-
105
- In your markup:
106
-
107
- ```html
108
- <svg class="icon">
109
- <use
110
- xmlns:xlink="http://www.w3.org/1999/xlink"
111
- xlink:href="/app/symbol/ffe-icons.svg#person-ikon"
112
- ></use>
113
- <!-- <desc>Alt text goes here</desc> -->
114
- </svg>
115
- ```
116
-
117
- Finally, depending on the current state of browsers and support requirements you may need to include the
118
- [SVG for Everybody](https://github.com/jonathantneal/svg4everybody) shim in your app.
119
-
120
- ## Adding a new icon
121
-
122
- So you've decided to contribute to our icons collection - that's great news! However, before you get started you should always consider if your icon would be useful to others outside your app/team. If you need help making that decision, or have any other questions - feel free to reach out to us either on Slack (#ext-designsystem) or via [GitHub Issues](https://github.com/SpareBank1/designsystem/issues).
123
-
124
- ### Optimizing
125
-
126
- Many of the most popular visual SVG editors tends to generate code that is _less than ideal_ for the web. In addition to larger files with unnecessary code, things like CSS might leak into other parts of your applications, or some wonky property might make your bundling system freak out. In other words - you should familiarize with the SVG code, and make sure you optimize it properly.
127
-
128
- - Remove unecessary code and properties. Tools like [this online SVG editor](https://petercollingridge.appspot.com/svg-editor) might be easier than manually using your editor.
129
-
130
- - Avoid using inline CSS. This might leak into other parts of your applications in addition to making it more complicated to control your from the outside. If you really have to use it - make sure the ID/classes you use are so unique that they wont interfer with any other styles.
131
-
132
- - Avoid embedding the primary color, this should be controlled by CSS. Other colors that shouldn't be overridable might be emdedded in the file.
133
-
134
- - The shape **must** fill the viewbox - minimum two edges of the square viewbox should be in contact with the shape. This is so margins can be fully controlled using CSS.
135
-
136
- ### Naming
137
-
138
- You should **always name your icon according to what it is**, not what it will be used for. For example, let's say you have an icon picturing a wheelchair which you plan to use as a health insurance icon. Instead of naming it "health insurance" you should rather use "wheelchair". That way, another team could easilly re-use the same icon for their "accessibility" page.
139
-
140
- ### Adding
141
-
142
- Once your icon is optimized and properly named, it's time to put it inside the `icons/` directory. At this point it might be a good idea to compare your icons to some existing ones. This might also be a good time to run `npm run build` to make sure everything works.
143
-
144
- If you've made it this far, it's time to make a pull request. If this is your first time, you should read our [contribution guidelines](https://github.com/SpareBank1/designsystem/blob/develop/CONTRIBUTING.md) first.
145
-
146
- ## Useful resources
147
-
148
- ### Links
149
-
150
- - [Online SVG Optimizer](https://petercollingridge.appspot.com/svg-editor)
151
- - [Online SVG editor](https://github.com/SVG-Edit/svgedit)
152
- - [SVGOMG](https://jakearchibald.github.io/svgomg/)
153
-
154
- ### Optimizing with Inkscape
155
-
156
- 1. Open the SVG file in Inkscape
157
- 2. SHIFT-CTRL-D Change the width and height to 200.
158
- 3. CTRL-A Select all elements.
159
- 4. SHIFT-CTRL-G Remove groups, (<g> elements). Repeat until no more groups.
160
- 5. CTRL-A and CTRL-'+' (Union) - Convert all elements to a single path. This may make the icon larger if the path is very complex.
161
- 6. SHIFT-CTRL-M Scale the icon until it fills the view box (vertical or horizontal), Hold SHIFT-CTRL to preserve ratio.
162
- 7. SHIFT-CTRL-S Save the icon as Optimized SVG
163
- 8. Open the icon in a text editor and check if it contains any transform attributes. If not, jump to 10.
164
- 9. Open the icon in http://editor.method.ac/ CTRL-A and choose Object->Reorient Path - This usually removes transforms. Save the file to disk.
165
- 10. Remove all metadata og unnecessary whitespace. The structure of the .svg file should be <svg viewBox="0 0 200 200" xmln"..."><path d="..."/></svg> [SVGOMG](https://jakearchibald.github.io/svgomg/) does a good job in removing cruft.
166
-
167
- ## Known issues
168
-
169
- See the current status on browser support for SVG fragments on [caniuse.com](caniuse.com/svg-fragment).
170
-
171
- - At time of writing, the generated SVG sprite cannot be used as a source for `background-image` in your CSS like "single" SVGs can
7
+ To use the new set of icons, please refer to [ffe-symbols](https://github.com/SpareBank1/designsystem/tree/develop/packages/ffe-symbols) and/or [ffe-symbols-react](https://github.com/SpareBank1/designsystem/tree/develop/packages/ffe-symbols-react).
package/bin/build.js CHANGED
@@ -1,60 +1,48 @@
1
- #!/usr/bin/env node
2
- 'use strict'; // eslint-disable-line strict
3
-
4
- const fs = require('fs');
5
1
  const path = require('path');
6
- const svgstore = require('svgstore');
7
- const mkdirp = require('mkdirp');
8
-
9
- const ICONS_PATH = path.join(__dirname, '..', 'icons');
10
-
11
- // convenience to avoid having file extension in config
12
- const appendSvgExtension = icons =>
13
- icons.map(name => (name.endsWith('.svg') ? name : `${name}.svg`));
14
-
15
- const options = require('yargs')
16
- .config('opts')
17
- .options({
18
- icons: {
19
- default: '**/*.svg',
20
- type: 'array',
21
- coerce: appendSvgExtension,
22
- },
23
- projectIcons: {
24
- type: 'array',
25
- coerce: appendSvgExtension,
26
- },
27
- dest: {
28
- default: 'dist',
29
- normalize: true,
30
- coerce: path.resolve,
31
- },
32
- }).argv;
33
-
34
- const matchesIcon = icons =>
35
- icons.includes('*.svg') || icons.includes('**/*.svg')
36
- ? () => true
37
- : fileName => icons.includes(path.basename(fileName));
38
-
39
- const sprite = svgstore();
40
-
41
- fs.readdirSync(ICONS_PATH)
42
- .filter(fileName => fileName.match(/\.svg$/))
43
- .filter(matchesIcon(options.icons))
44
- .forEach(fileName => {
45
- const iconPath = path.join(ICONS_PATH, fileName);
46
- const iconName = path.basename(fileName, '.svg');
47
- sprite.add(iconName, fs.readFileSync(iconPath), 'utf-8');
48
- });
49
-
50
- if (options.projectIcons) {
51
- options.projectIcons.forEach(fileName => {
52
- const iconPath = path.join(fileName);
53
- const iconName = path.basename(fileName, '.svg');
54
- sprite.add(iconName, fs.readFileSync(iconPath), 'utf-8');
55
- });
56
- }
57
-
58
- mkdirp.sync(options.dest);
59
-
60
- fs.writeFileSync(path.join(options.dest, 'ffe-icons.svg'), sprite.toString());
2
+ const fs = require('fs');
3
+ const { makedirs } = require('./utils');
4
+ const { getIconNames } = require('./getIconNames');
5
+ const { getDownloads, downloadAll } = require('./downloadSvgs');
6
+ const {
7
+ createListOfRemovedIcons,
8
+ deleteRemovedIconsFiles,
9
+ } = require('./deleteSvg');
10
+
11
+ (async () => {
12
+ const weights = [300, 500];
13
+ const sizes = [
14
+ { name: 'sm', opsz: 20 },
15
+ { name: 'md', opsz: 24 },
16
+ { name: 'lg', opsz: 40 },
17
+ { name: 'xl', opsz: 48 },
18
+ ];
19
+ const fill = [0, 1];
20
+
21
+ const iconNames = await getIconNames();
22
+ const listOfRemovedIcons = await createListOfRemovedIcons(iconNames);
23
+ let downloads = [];
24
+
25
+ for (const weight of weights) {
26
+ for (const fillValue of fill) {
27
+ const type = fillValue === 0 ? 'filled' : 'open';
28
+ for (const size of sizes) {
29
+ const dirPath = path.resolve(
30
+ __dirname,
31
+ `../icons/${weight}/${type}/${size.name}`,
32
+ );
33
+ if (!fs.existsSync(dirPath)) {
34
+ await makedirs(dirPath);
35
+ }
36
+ if (listOfRemovedIcons.length > 0) {
37
+ await deleteRemovedIconsFiles(listOfRemovedIcons, dirPath);
38
+ }
39
+ downloads = downloads.concat(
40
+ getDownloads(iconNames, weight, fillValue, size, dirPath),
41
+ );
42
+ }
43
+ }
44
+ }
45
+ console.log('Downloading SVG files...');
46
+ await downloadAll(downloads);
47
+ console.log('All done!');
48
+ })();
@@ -0,0 +1,2 @@
1
+ @import 'theme';
2
+ @import 'icons';
@@ -0,0 +1,26 @@
1
+ .ffe-icons {
2
+ color: var(--ffe-v-icons-default-color);
3
+ mask-repeat: no-repeat;
4
+ background-color: currentColor;
5
+ display: inline-block;
6
+
7
+ &--sm {
8
+ height: var(--ffe-v-icons-size-sm);
9
+ width: var(--ffe-v-icons-size-sm);
10
+ }
11
+
12
+ &--md {
13
+ height: var(--ffe-v-icons-size-md);
14
+ width: var(--ffe-v-icons-size-md);
15
+ }
16
+
17
+ &--lg {
18
+ height: var(--ffe-v-icons-size-lg);
19
+ width: var(--ffe-v-icons-size-lg);
20
+ }
21
+
22
+ &--xl {
23
+ height: var(--ffe-v-icons-size-xl);
24
+ width: var(--ffe-v-icons-size-xl);
25
+ }
26
+ }
@@ -0,0 +1,14 @@
1
+ :root,
2
+ :host {
3
+ --ffe-v-icons-size-sm: 20px;
4
+ --ffe-v-icons-size-md: 24px;
5
+ --ffe-v-icons-size-lg: 40px;
6
+ --ffe-v-icons-size-xl: 48px;
7
+ --ffe-v-icons-default-color: var(--ffe-farge-vann);
8
+
9
+ .native & {
10
+ @media (prefers-color-scheme: dark) {
11
+ --ffe-v-icons-default-color: var(--ffe-farge-vann-70);
12
+ }
13
+ }
14
+ }
package/package.json CHANGED
@@ -1,31 +1,35 @@
1
1
  {
2
- "name": "@sb1/ffe-icons",
3
- "version": "12.17.0",
4
- "description": "Felles Front End Icons",
5
- "license": "MIT",
6
- "author": "SpareBank 1",
7
- "bin": {
8
- "ffe-icons": "bin/build.js"
9
- },
10
- "repository": {
11
- "type": "git",
12
- "url": "ssh://git@github.com:SpareBank1/designsystem.git"
13
- },
14
- "scripts": {
15
- "build": "node bin/build.js",
16
- "lint": "eslint bin",
17
- "test": "npm run lint"
18
- },
19
- "dependencies": {
20
- "mkdirp": "^1.0.4",
21
- "svgstore": "^2.0.3",
22
- "yargs": "^16.0.0"
23
- },
24
- "devDependencies": {
25
- "eslint": "^5.9.0"
26
- },
27
- "publishConfig": {
28
- "access": "public"
29
- },
30
- "gitHead": "e900240c8817faf27fdccbc479905958b4c5aa79"
2
+ "name": "@sb1/ffe-icons",
3
+ "version": "13.0.0",
4
+ "description": "Felles Front End Icons",
5
+ "license": "MIT",
6
+ "author": "SpareBank 1",
7
+ "bin": {
8
+ "ffe-icons": "bin/build.js"
9
+ },
10
+ "files": [
11
+ "less"
12
+ ],
13
+ "repository": {
14
+ "type": "git",
15
+ "url": "ssh://git@github.com:SpareBank1/designsystem.git"
16
+ },
17
+ "scripts": {
18
+ "build:": "",
19
+ "build:icons": "node bin/build.js",
20
+ "lint": "eslint bin",
21
+ "test": "npm run lint"
22
+ },
23
+ "dependencies": {
24
+ "mkdirp": "^1.0.4",
25
+ "svgstore": "^3.0.1",
26
+ "yargs": "^16.0.0"
27
+ },
28
+ "devDependencies": {
29
+ "eslint": "^5.9.0"
30
+ },
31
+ "publishConfig": {
32
+ "access": "public"
33
+ },
34
+ "gitHead": "ec6e0f6b13650b53140c606652e102cb52209c2c"
31
35
  }