diff --git a/README.md b/README.md index 82e8951..d99ed2c 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,8 @@ Hyvä Flags extension by [JaJuMa](https://www.jajuma.de/de/jajuma-shop/online-sh The module includes: * Square Flag Icons (1:1 ratio) -* Rectangle Flag Icons (4:3 ratio) & +* Rectangle Flag Icons (3:2 + 4:3 ratio) +* Official Flag Sizes & * Circle Flag Icons @@ -38,11 +39,13 @@ composer require jajuma/hyva-flags ### How to use country & language flag icons in Hyvä Themes in view models -JaJuMa "Hyvä Flags" module provides 3 view models: +JaJuMa "Hyvä Flags" module provides 5 view models: * `Flagicons11` +* `Flagicons32` * `Flagicons43` * `FlagiconsCircle` +* `FlagiconsOfficial` Require one of the view models in your template: @@ -51,6 +54,10 @@ Require one of the view models in your template: $flagicons11 = $viewModels->require(\Jajuma\HyvaFlags\ViewModel\Flagicons11::class); ``` ``` +/** @var \Jajuma\HyvaFlags\ViewModel\Flagicons32 $flagicons32 */ +$flagicons32 = $viewModels->require(\Jajuma\HyvaFlags\ViewModel\Flagicons32::class); +``` +``` /** @var \Jajuma\HyvaFlags\ViewModel\Flagicons43 $flagicons43 */ $flagicons43 = $viewModels->require(\Jajuma\HyvaFlags\ViewModel\Flagicons43::class); ``` @@ -58,6 +65,10 @@ $flagicons43 = $viewModels->require(\Jajuma\HyvaFlags\ViewModel\Flagicons43::cla /** @var \Jajuma\HyvaFlags\ViewModel\FlagiconsCircle $flagiconscircle */ $flagiconscircle = $viewModels->require(\Jajuma\HyvaFlags\ViewModel\FlagiconsCircle::class); ``` +``` +/** @var \Jajuma\HyvaFlags\ViewModel\FlagiconsOfficial $flagiconsofficial */ +$flagiconsofficial = $viewModels->require(\Jajuma\HyvaFlags\ViewModel\FlagiconsOfficial::class); +``` Then render the icons like this: ``` @@ -104,8 +115,10 @@ The code is licensed under the [MIT License (MIT)](https://github.com/JaJuMa/Hyv ## Credits Credits for the SVG icons: -* Square & Rectangle Format: [@lipis](https://github.com/lipis/flag-icons) +* Square & Rectangle Format 4:3: [@lipis](https://github.com/lipis/flag-icons) +* Rectangle Format 3:2: [@catamphetamine](https://github.com/catamphetamine/country-flag-icons) * Circle format: [@HatScripts](https://github.com/HatScripts/circle-flag) +* Official sizes: [@hampusborgos](https://github.com/hampusborgos/country-flags) ## Other [Magento 2 Extensions](ttps://www.jajuma.de/en/jajuma-develop/magento-extensions) by [JaJuMa](https://www.jajuma.de/) diff --git a/view/frontend/web/svg/3x2/LICENSE b/view/frontend/web/svg/3x2/LICENSE new file mode 100644 index 0000000..84e028a --- /dev/null +++ b/view/frontend/web/svg/3x2/LICENSE @@ -0,0 +1,22 @@ +(The MIT License) + +Copyright (c) 2020 @catamphetamine + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +'Software'), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY +CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, +TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE +SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \ No newline at end of file diff --git a/view/frontend/web/svg/3x2/ru.svg b/view/frontend/web/svg/3x2/ru.svg index 1117270..87cd1c0 100644 --- a/view/frontend/web/svg/3x2/ru.svg +++ b/view/frontend/web/svg/3x2/ru.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/view/frontend/web/svg/official/ru.svg b/view/frontend/web/svg/official/ru.svg index 6e65fbd..7ec615c 100755 --- a/view/frontend/web/svg/official/ru.svg +++ b/view/frontend/web/svg/official/ru.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file