Class: PhlexIcons::Flag::Jp

Inherits:
Base
  • Object
show all
Defined in:
lib/phlex-icons/flag/jp.rb

Instance Attribute Summary

Attributes inherited from Base

#attrs

Instance Method Summary collapse

Methods inherited from Base

#initialize, #view_template

Constructor Details

This class inherits a constructor from PhlexIcons::Base

Instance Method Details

#rectangleObject



34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# File 'lib/phlex-icons/flag/jp.rb', line 34

def rectangle
  svg(
    **attrs, xmlns: 'http://www.w3.org/2000/svg', viewbox: '0 0 640 480'
  ) do |s|
    s.defs do
      s.clipPath(id: 'jp-a') do
        s.path(fill_opacity: '.7', d: 'M-88 32h640v480H-88z')
      end
    end
    s.g(
      fill_rule: 'evenodd',
      stroke_width: '1pt',
      clip_path: 'url(#jp-a)',
      transform: 'translate(88 -32)'
    ) do
      s.path(fill: '#fff', d: 'M-128 32h720v480h-720z')
      s.circle(
        cx: '523.1',
        cy: '344.1',
        r: '194.9',
        fill: '#bc002d',
        transform: 'translate(-168.4 8.6)scale(.76554)'
      )
    end
  end
end

#squareObject



7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# File 'lib/phlex-icons/flag/jp.rb', line 7

def square
  svg(
    **attrs, xmlns: 'http://www.w3.org/2000/svg', viewbox: '0 0 512 512'
  ) do |s|
    s.defs do
      s.clipPath(id: 'jp-a') do
        s.path(fill_opacity: '.7', d: 'M177.2 0h708.6v708.7H177.2z')
      end
    end
    s.g(
      fill_rule: 'evenodd',
      stroke_width: '1pt',
      clip_path: 'url(#jp-a)',
      transform: 'translate(-128)scale(.72249)'
    ) do
      s.path(fill: '#fff', d: 'M0 0h1063v708.7H0z')
      s.circle(
        cx: '523.1',
        cy: '344.1',
        r: '194.9',
        fill: '#bc002d',
        transform: 'translate(-59.7 -34.5)scale(1.1302)'
      )
    end
  end
end