Skip to content

Releases: MohmmedAshraf/blade-flags

js-v0.1.3

23 Feb 02:04

Choose a tag to compare

Fix

  • Fix flag components not respecting CSS size classes (size-4, shrink-0, etc.)
    • Strip hardcoded width/height from SVGs, use width:100%;height:100% so the SVG fills its container
    • Add display:inline-flex to the span wrapper

Affected packages: @blade-flags/core, @blade-flags/react, @blade-flags/vue

v1.6.1

14 Feb 14:51

Choose a tag to compare

This package aims for broad compatibility by mirroring upstream flag collections. Inclusion of any flag does not imply endorsement. The author of this package stands with Palestine PS Flag (the Palestine flag is featured in the project cover). If you want to exclude specific flags, you can do so in your application/UI, or exclude them during the build via bin/build.sh.

JS v0.1.2

14 Feb 14:51

Choose a tag to compare

This package aims for broad compatibility by mirroring upstream flag collections. Inclusion of any flag does not imply endorsement. The author of this package stands with Palestine PS Flag (the Palestine flag is featured in the project cover). If you want to exclude specific flags, you can do so in your application/UI, or exclude them during the build via bin/build.sh.

v1.6.0

13 Feb 17:41

Choose a tag to compare

What's New

Circle & Flat Flag Variants

The package now ships with three flag styles — 1,759 flags total:

Variant Component Countries Languages
Default (rounded) <x-flag-country-us /> 264 281
Circle <x-flag-circle-country-us /> 405 275
Flat (4:3) <x-flag-flat-country-us /> 270 264

Language Flag Overrides

Override default language-to-country mappings via config:

// config/blade-flags.php
'language_overrides' => [
    'ar' => ['default' => 'sa'],
    'en' => ['default' => 'us'],
],

JavaScript Packages

The same flags are now available as npm packages for Vue, React, and vanilla JS:

  • @blade-flags/core — SVG strings as tree-shakeable JS modules
  • @blade-flags/vue<Flag> component for Vue 3
  • @blade-flags/react<Flag> component for React 18+
npm install @blade-flags/core @blade-flags/vue

Full Changelog: 1.5.4...1.6.0

JS v0.1.1

13 Feb 17:44

Choose a tag to compare

Fixed

  • Add README files to npm packages

JS v0.1.0

13 Feb 17:41

Choose a tag to compare

Initial Release — JavaScript Packages

First release of the JavaScript flag packages, providing the same 1,759 SVG flags from blade-flags as tree-shakeable JS modules.

Packages

Package Description
@blade-flags/core SVG strings as JS modules + resolveFlag() helper
@blade-flags/vue <Flag> component for Vue 3.3+
@blade-flags/react <Flag> component for React 18+

Installation

npm install @blade-flags/core @blade-flags/vue   # Vue
npm install @blade-flags/core @blade-flags/react  # React
npm install @blade-flags/core                     # Vanilla JS

Tree-Shaking

Every flag is a named export — import only what you need:

import { countryUs, countryGb } from '@blade-flags/core/flags/circle'

Or use the full variant map for dynamic runtime lookup:

import { circleFlags } from '@blade-flags/core/flags/circle'
import { resolveFlag } from '@blade-flags/core'
const svg = resolveFlag(circleFlags, 'us')

v1.5.4

30 Aug 07:17
f467991

Choose a tag to compare

What's Changed

New Contributors

Full Changelog: 1.5.3...1.5.4

v1.5.3

24 Feb 15:05
84d37c6

Choose a tag to compare

What's Changed

Full Changelog: 1.5.2...1.5.3

v1.5.2

26 Dec 05:33
433a9b0

Choose a tag to compare

What's Changed

  • Updated Syrian Flag to the New Free Syria Green Flag by @JamelSyr in #23

New Contributors

Full Changelog: 1.5.1...1.5.2

1.5.1

23 Apr 09:01
fc630fc

Choose a tag to compare

What's Changed

New Contributors

Full Changelog: 1.5.0...1.5.1