vipassana-design-standards 1.1.1 → 1.1.3

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 897158aee96e278f8c0a3d4d3352cd981d4aac4da97b34e23d8b28a1d0bf91bc
4
- data.tar.gz: 007ddb2cf1f66ea42762a6eaa23cc6aeca6e9462ca20eeee79a08401e86fb055
3
+ metadata.gz: 4e81268de98d3ebe0fc8e7bf348af7280742d6a6437b492a28655b8307b2057b
4
+ data.tar.gz: a7858f4c6bd56d48a365e3f312f02aa0bd6f638b76471446351b6ab9098adbfb
5
5
  SHA512:
6
- metadata.gz: 5b28e4f2e922d2f7814d4e7cb6cd8d41d3e61f10f0d07639b7617e409890912b7ff363d93dd254526bdbb560b8b856ea0fc7335a9ccd22eab7ca1478418c5200
7
- data.tar.gz: 29b6e04c84c6991039dce7af5d859b65a3b51ab94fb8c373463dc561e3d95554bfdaabf6137367e7b9afb790ad04db0bd20579f738889d03bc87bc0af9337cec
6
+ metadata.gz: 19b0f0842bb2381a350b5d3fc924d94ee1766bf0a1ba3a21bcdee3fbb214ab2185d09a44dd108546d809c8374013f7f0cf2c92c5c85c70edb6c70e445071bf0c
7
+ data.tar.gz: 40f80ccc78189f9fef53cb8df67e2845e7a8646480b844144f168340e1aa59a0fcb262304df1695c9ecd60f8d11ae25cc0fc2c42c76669f3ea8f7c2f26d86aaf
@@ -54,9 +54,19 @@ module Vipassana
54
54
  javascript_include_tag vds_asset_url("js/bootstrap5-theme.min.js", localhost)
55
55
  end
56
56
 
57
- def vds_logo(locale: I18n.locale, disposition: "default", size: '17', tagline: true, dark: false)
57
+ def vds_logo(locale: I18n.locale, disposition: "default", size: '17', tagline: true, dark: false, use_english: true)
58
58
  locale = fix_locale(locale)
59
- trans = VDS_TRANSLATIONS[locale.to_sym] || VDS_TRANSLATIONS[:en]
59
+ english_trans = VDS_TRANSLATIONS[:en]
60
+ trans = VDS_TRANSLATIONS[locale.to_sym] || english_trans
61
+ full_text = trans[:full] || "#{trans[:vipassana_meditation]} #{trans[:as_taught]} #{trans[:in_the_tradition]}"
62
+
63
+ title = nil
64
+ # Recommendation from trademark team : display logo in english, we can add translation on mouse hover
65
+ if use_english && locale.to_sym != :en
66
+ locale = :en
67
+ trans = english_trans
68
+ title = full_text
69
+ end
60
70
 
61
71
  if disposition == "mobile"
62
72
  disposition = "left-two-lines"
@@ -70,8 +80,9 @@ module Vipassana
70
80
  data-tagline="#{tagline}"
71
81
  data-dark-mode="#{dark}"
72
82
  data-reverse="#{trans[:reverse]}"
83
+ title="#{title}"
73
84
  style="font-size: #{size}px">
74
- <img class="logo-wheel" src="https://design-standards.dhamma.org/dist/dhamma-wheel.svg" />
85
+ <img class="logo-wheel" src="https://design-standards.dhamma.org/dist/dhamma-wheel.svg" alt="#{full_text}" />
75
86
  <div class="logo-text">
76
87
  <h1 class="logo-title">
77
88
  <span data-start-with="#{trans[:vipassana_meditation].at(0).downcase}">
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vipassana-design-standards
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 1.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dhamma workers
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-04-19 00:00:00.000000000 Z
11
+ date: 2024-08-19 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Provide a custom bootstrap theme, logos and icons according to the design
14
14
  standards of Vipassana Meditation as Taught yb S.N. Goenka
@@ -26,7 +26,7 @@ files:
26
26
  homepage: https://design-standards.dhamma.org
27
27
  licenses: []
28
28
  metadata: {}
29
- post_install_message:
29
+ post_install_message:
30
30
  rdoc_options: []
31
31
  require_paths:
32
32
  - lib
@@ -41,8 +41,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
41
41
  - !ruby/object:Gem::Version
42
42
  version: '0'
43
43
  requirements: []
44
- rubygems_version: 3.2.5
45
- signing_key:
44
+ rubygems_version: 3.3.15
45
+ signing_key:
46
46
  specification_version: 4
47
47
  summary: Helper to include UI components in your pages
48
48
  test_files: []