vipassana-design-standards 0.0.37 → 1.1.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 (60) hide show
  1. package/README.md +46 -39
  2. package/dist/css/bootstrap5-theme.css +158 -128
  3. package/dist/css/bootstrap5-theme.css.map +1 -1
  4. package/dist/css/bootstrap5-theme.min.css +1 -1
  5. package/dist/css/bootstrap5-theme.rtl.css +158 -128
  6. package/dist/css/bootstrap5-theme.rtl.min.css +1 -1
  7. package/dist/css/fonts-ar.css +13 -5
  8. package/dist/css/fonts-fa.css +13 -5
  9. package/dist/css/fonts-gu.css +23 -11
  10. package/dist/css/fonts-he.css +23 -11
  11. package/dist/css/fonts-ja.css +2367 -473
  12. package/dist/css/fonts-km.css +23 -11
  13. package/dist/css/fonts-ko.css +1935 -471
  14. package/dist/css/fonts-or.css +23 -11
  15. package/dist/css/fonts-si.css +23 -11
  16. package/dist/css/fonts-ta.css +23 -11
  17. package/dist/css/fonts-te.css +23 -11
  18. package/dist/css/fonts-th.css +23 -11
  19. package/dist/css/fonts-zh-HANS.css +2271 -389
  20. package/dist/css/fonts-zh-HANT-HK.css +2901 -421
  21. package/dist/css/fonts-zh-HANT.css +2443 -405
  22. package/dist/css/fonts.css.map +1 -1
  23. package/dist/css/logo.css +39 -17
  24. package/dist/css/logo.css.map +1 -1
  25. package/dist/css/logo.min.css +1 -1
  26. package/dist/css/logo.rtl.css +39 -17
  27. package/dist/css/logo.rtl.min.css +1 -1
  28. package/dist/js/bootstrap5-theme.min.js +12 -12
  29. package/dist/js/helpers.js +42 -29
  30. package/dist/js/i18n.js +319 -319
  31. package/dist/js/react-helpers.js +164 -0
  32. package/dist/js/react-helpers.jsx +106 -42
  33. package/package.json +11 -3
  34. package/src/stylesheets/bootstrap5-theme.scss +11 -11
  35. package/src/stylesheets/custom-bootstrap-utilities.scss +129 -50
  36. package/src/stylesheets/custom-bootstrap-variables.scss +45 -36
  37. package/src/stylesheets/custom-bootstrap.scss +17 -13
  38. package/src/stylesheets/fonts.scss +234 -70
  39. package/src/stylesheets/index.css +24 -22
  40. package/src/stylesheets/layout/vds-header.scss +3 -3
  41. package/src/stylesheets/layout/vds-layout.scss +6 -5
  42. package/src/stylesheets/layout/vds-mixins.scss +1 -1
  43. package/src/stylesheets/layout/vds-sidenav.scss +3 -2
  44. package/src/stylesheets/logo.scss +94 -78
  45. package/src/stylesheets/mixins.scss +2 -2
  46. package/src/stylesheets/specific-fonts/fonts-ar.css +13 -5
  47. package/src/stylesheets/specific-fonts/fonts-fa.css +13 -5
  48. package/src/stylesheets/specific-fonts/fonts-gu.css +23 -11
  49. package/src/stylesheets/specific-fonts/fonts-he.css +23 -11
  50. package/src/stylesheets/specific-fonts/fonts-ja.css +2367 -473
  51. package/src/stylesheets/specific-fonts/fonts-km.css +23 -11
  52. package/src/stylesheets/specific-fonts/fonts-ko.css +1935 -471
  53. package/src/stylesheets/specific-fonts/fonts-or.css +23 -11
  54. package/src/stylesheets/specific-fonts/fonts-si.css +23 -11
  55. package/src/stylesheets/specific-fonts/fonts-ta.css +23 -11
  56. package/src/stylesheets/specific-fonts/fonts-te.css +23 -11
  57. package/src/stylesheets/specific-fonts/fonts-th.css +23 -11
  58. package/src/stylesheets/specific-fonts/fonts-zh-HANS.css +2271 -389
  59. package/src/stylesheets/specific-fonts/fonts-zh-HANT-HK.css +2901 -421
  60. package/src/stylesheets/specific-fonts/fonts-zh-HANT.css +2443 -405
@@ -0,0 +1,164 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.VdsBootstrapThemeCssTag = VdsBootstrapThemeCssTag;
7
+ exports.VdsBootstrapThemeJsTag = VdsBootstrapThemeJsTag;
8
+ exports.VdsFaviconTag = VdsFaviconTag;
9
+ exports.VdsIconAccount = VdsIconAccount;
10
+ exports.VdsIconLocale = VdsIconLocale;
11
+ exports.VdsIconMenu = VdsIconMenu;
12
+ exports.VdsLogo = VdsLogo;
13
+ var _i18n = _interopRequireDefault(require("./i18n.js"));
14
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
15
+ function fixLocale(locale) {
16
+ locale = (locale || 'en').toLowerCase();
17
+ var mapping = {
18
+ zh: 'zh-HANS',
19
+ 'zh-hans': 'zh-HANS',
20
+ 'zh-hant': 'zh-HANT',
21
+ 'zh-hant-hk': 'zh-HANT-HK',
22
+ 'zh-hk': 'zh-HANT-HK',
23
+ 'zh-cn': 'zh-HANS',
24
+ 'zh-tw': 'zh-HANT'
25
+ };
26
+ if (mapping[locale]) locale = mapping[locale]; // zh-Hans -> zh-HANS
27
+ else locale = locale.split('-')[0]; // fr-CA -> fr
28
+ return locale;
29
+ }
30
+ function isRtl(locale) {
31
+ return ['ar', 'fa', 'he'].includes(locale);
32
+ }
33
+ function vdsAssetUrl(path) {
34
+ var localhost = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
35
+ // For localhost dev, just run vscode liveserver
36
+ if (localhost) return "http://localhost:5500/dist/".concat(path);
37
+ return "https://design-standards.dhamma.org/dist/1.1.0/".concat(path);
38
+ }
39
+ function StylesheetLinkTag(_ref) {
40
+ var url = _ref.url;
41
+ return /*#__PURE__*/React.createElement("link", {
42
+ rel: "stylesheet",
43
+ type: "text/css",
44
+ href: url
45
+ });
46
+ }
47
+ function VdsFaviconTag() {
48
+ return /*#__PURE__*/React.createElement("link", {
49
+ rel: "shortcut icon",
50
+ type: "image/x-icon",
51
+ href: "https://design-standards.dhamma.org/dist/favicon.png"
52
+ });
53
+ }
54
+ function VdsBootstrapThemeCssTag(_ref2) {
55
+ var locale = _ref2.locale,
56
+ _ref2$localhost = _ref2.localhost,
57
+ localhost = _ref2$localhost === void 0 ? false : _ref2$localhost;
58
+ locale = fixLocale(locale);
59
+ var url = vdsAssetUrl("css/bootstrap5-theme".concat(isRtl(locale) ? '.rtl' : '', ".min.css"), localhost);
60
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(StylesheetLinkTag, {
61
+ url: url
62
+ }), ['ar', 'fa', 'gu', 'he', 'ja', 'km', 'ko', 'or', 'si', 'ta', 'te', 'th', 'zh-HANS', 'zh-HANT', 'zh-HANT-HK'].includes(locale) && /*#__PURE__*/React.createElement(StylesheetLinkTag, {
63
+ url: vdsAssetUrl("css/fonts-".concat(locale, ".min.css"))
64
+ }));
65
+ }
66
+ function VdsBootstrapThemeJsTag(_ref3) {
67
+ var _ref3$localhost = _ref3.localhost,
68
+ localhost = _ref3$localhost === void 0 ? false : _ref3$localhost;
69
+ var url = vdsAssetUrl('js/bootstrap5-theme.min.js', localhost);
70
+ return /*#__PURE__*/React.createElement("script", {
71
+ type: "text/javascript",
72
+ src: url
73
+ });
74
+ }
75
+ function VdsLogo(_ref4) {
76
+ var locale = _ref4.locale,
77
+ _ref4$disposition = _ref4.disposition,
78
+ disposition = _ref4$disposition === void 0 ? 'default' : _ref4$disposition,
79
+ _ref4$size = _ref4.size,
80
+ size = _ref4$size === void 0 ? '17' : _ref4$size,
81
+ _ref4$tagline = _ref4.tagline,
82
+ tagline = _ref4$tagline === void 0 ? true : _ref4$tagline,
83
+ _ref4$dark = _ref4.dark,
84
+ dark = _ref4$dark === void 0 ? false : _ref4$dark;
85
+ locale = fixLocale(locale);
86
+ var trans = _i18n["default"][locale] || _i18n["default"].en;
87
+ if (disposition == 'mobile') {
88
+ disposition = 'left-two-lines';
89
+ tagline = false;
90
+ }
91
+ return /*#__PURE__*/React.createElement("div", {
92
+ className: "vipassana-logo",
93
+ "data-lang": locale,
94
+ "data-disposition": disposition,
95
+ "data-tagline": tagline,
96
+ "data-dark-mode": dark,
97
+ "data-reverse": trans.reverse,
98
+ style: {
99
+ fontSize: "".concat(size, "px")
100
+ }
101
+ }, /*#__PURE__*/React.createElement("img", {
102
+ className: "logo-wheel",
103
+ src: "https://design-standards.dhamma.org/dist/dhamma-wheel.svg"
104
+ }), /*#__PURE__*/React.createElement("div", {
105
+ className: "logo-text"
106
+ }, /*#__PURE__*/React.createElement("h1", {
107
+ className: "logo-title"
108
+ }, /*#__PURE__*/React.createElement("span", {
109
+ "data-start-with": trans.vipassana_meditation.charAt(0).toLowerCase()
110
+ }, trans.vipassana_meditation), /*#__PURE__*/React.createElement("span", {
111
+ className: "logo-space"
112
+ }, "\xA0"), /*#__PURE__*/React.createElement("span", null, trans.as_taught), /*#__PURE__*/React.createElement("span", {
113
+ className: "vipassana-as-taught"
114
+ }, trans.vipassana_as_taught)), /*#__PURE__*/React.createElement("div", {
115
+ className: "logo-subtitle"
116
+ }, trans.in_the_tradition)));
117
+ }
118
+
119
+ // Some icons from bootstrap icons, so all websites use the same
120
+ function VdsIconLocale(_ref5) {
121
+ var _ref5$size = _ref5.size,
122
+ size = _ref5$size === void 0 ? 1.2 : _ref5$size;
123
+ return /*#__PURE__*/React.createElement("svg", {
124
+ xmlns: "http://www.w3.org/2000/svg",
125
+ width: "".concat(size, "em"),
126
+ height: "".concat(size, "em"),
127
+ fill: "currentColor",
128
+ viewBox: "0 0 16 16"
129
+ }, /*#__PURE__*/React.createElement("path", {
130
+ d: "M4.545 6.714 4.11 8H3l1.862-5h1.284L8 8H6.833l-.435-1.286H4.545zm1.634-.736L5.5 3.956h-.049l-.679 2.022H6.18z"
131
+ }), /*#__PURE__*/React.createElement("path", {
132
+ d: "M0 2a2 2 0 0 1 2-2h7a2 2 0 0 1 2 2v3h3a2 2 0 0 1 2 2v7a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2v-3H2a2 2 0 0 1-2-2V2zm2-1a1 1 0 0 0-1 1v7a1 1 0 0 0 1 1h7a1 1 0 0 0 1-1V2a1 1 0 0 0-1-1H2zm7.138 9.995c.193.301.402.583.63.846-.748.575-1.673 1.001-2.768 1.292.178.217.451.635.555.867 1.125-.359 2.08-.844 2.886-1.494.777.665 1.739 1.165 2.93 1.472.133-.254.414-.673.629-.89-1.125-.253-2.057-.694-2.82-1.284.681-.747 1.222-1.651 1.621-2.757H14V8h-3v1.047h.765c-.318.844-.74 1.546-1.272 2.13a6.066 6.066 0 0 1-.415-.492 1.988 1.988 0 0 1-.94.31z"
133
+ }));
134
+ }
135
+ function VdsIconAccount(_ref6) {
136
+ var _ref6$size = _ref6.size,
137
+ size = _ref6$size === void 0 ? 2.2 : _ref6$size;
138
+ return /*#__PURE__*/React.createElement("svg", {
139
+ xmlns: "http://www.w3.org/2000/svg",
140
+ width: "".concat(size, "em"),
141
+ height: "".concat(size, "em"),
142
+ fill: "currentColor",
143
+ viewBox: "0 0 16 16"
144
+ }, /*#__PURE__*/React.createElement("path", {
145
+ d: "M11 6a3 3 0 1 1-6 0 3 3 0 0 1 6 0z"
146
+ }), /*#__PURE__*/React.createElement("path", {
147
+ fillRule: "evenodd",
148
+ d: "M0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8zm8-7a7 7 0 0 0-5.468 11.37C3.242 11.226 4.805 10 8 10s4.757 1.225 5.468 2.37A7 7 0 0 0 8 1z"
149
+ }));
150
+ }
151
+ function VdsIconMenu(_ref7) {
152
+ var _ref7$size = _ref7.size,
153
+ size = _ref7$size === void 0 ? 1.8 : _ref7$size;
154
+ return /*#__PURE__*/React.createElement("svg", {
155
+ xmlns: "http://www.w3.org/2000/svg",
156
+ width: "".concat(size, "em"),
157
+ height: "".concat(size, "em"),
158
+ fill: "currentColor",
159
+ viewBox: "0 0 16 16"
160
+ }, /*#__PURE__*/React.createElement("path", {
161
+ fillRule: "evenodd",
162
+ d: "M2.5 12a.5.5 0 0 1 .5-.5h10a.5.5 0 0 1 0 1H3a.5.5 0 0 1-.5-.5zm0-4a.5.5 0 0 1 .5-.5h10a.5.5 0 0 1 0 1H3a.5.5 0 0 1-.5-.5zm0-4a.5.5 0 0 1 .5-.5h10a.5.5 0 0 1 0 1H3a.5.5 0 0 1-.5-.5z"
163
+ }));
164
+ }
@@ -3,16 +3,16 @@ import i18n from './i18n.js'
3
3
  function fixLocale(locale) {
4
4
  locale = (locale || 'en').toLowerCase()
5
5
  const mapping = {
6
- 'zh': 'zh-HANS',
6
+ zh: 'zh-HANS',
7
7
  'zh-hans': 'zh-HANS',
8
8
  'zh-hant': 'zh-HANT',
9
9
  'zh-hant-hk': 'zh-HANT-HK',
10
10
  'zh-hk': 'zh-HANT-HK',
11
11
  'zh-cn': 'zh-HANS',
12
- 'zh-tw': 'zh-HANT',
12
+ 'zh-tw': 'zh-HANT'
13
13
  }
14
14
  if (mapping[locale]) locale = mapping[locale] // zh-Hans -> zh-HANS
15
- else locale = locale.split("-")[0] // fr-CA -> fr
15
+ else locale = locale.split('-')[0] // fr-CA -> fr
16
16
  return locale
17
17
  }
18
18
 
@@ -24,79 +24,143 @@ function vdsAssetUrl(path, localhost = false) {
24
24
  // For localhost dev, just run vscode liveserver
25
25
  if (localhost) return `http://localhost:5500/dist/${path}`
26
26
 
27
- return `https://design-standards.dhamma.org/dist/0.0.37/${path}`
27
+ return `https://design-standards.dhamma.org/dist/1.1.0/${path}`
28
28
  }
29
29
 
30
- function StylesheetLinkTag({url}) {
30
+ function StylesheetLinkTag({ url }) {
31
31
  return <link rel="stylesheet" type="text/css" href={url} />
32
32
  }
33
33
 
34
34
  export function VdsFaviconTag() {
35
- return <link rel="shortcut icon" type="image/x-icon" href="https://design-standards.dhamma.org/dist/favicon.png" />
35
+ return (
36
+ <link
37
+ rel="shortcut icon"
38
+ type="image/x-icon"
39
+ href="https://design-standards.dhamma.org/dist/favicon.png"
40
+ />
41
+ )
36
42
  }
37
43
 
38
44
  export function VdsBootstrapThemeCssTag({ locale, localhost = false }) {
39
45
  locale = fixLocale(locale)
40
46
  const url = vdsAssetUrl(`css/bootstrap5-theme${isRtl(locale) ? '.rtl' : ''}.min.css`, localhost)
41
- return <>
42
- <StylesheetLinkTag url={url}/>
43
- {['ar', 'fa', 'gu', 'he', 'ja', 'km', 'ko', 'or', 'si', 'ta', 'te', 'th', 'zh-HANS', 'zh-HANT', 'zh-HANT-HK'].includes(locale) && <StylesheetLinkTag url={vdsAssetUrl(`css/fonts-${locale}.min.css`)}/>}
44
- </>
47
+ return (
48
+ <>
49
+ <StylesheetLinkTag url={url} />
50
+ {[
51
+ 'ar',
52
+ 'fa',
53
+ 'gu',
54
+ 'he',
55
+ 'ja',
56
+ 'km',
57
+ 'ko',
58
+ 'or',
59
+ 'si',
60
+ 'ta',
61
+ 'te',
62
+ 'th',
63
+ 'zh-HANS',
64
+ 'zh-HANT',
65
+ 'zh-HANT-HK'
66
+ ].includes(locale) && <StylesheetLinkTag url={vdsAssetUrl(`css/fonts-${locale}.min.css`)} />}
67
+ </>
68
+ )
45
69
  }
46
70
 
47
71
  export function VdsBootstrapThemeJsTag({ localhost = false }) {
48
- const url = vdsAssetUrl("js/bootstrap5-theme.min.js", localhost)
72
+ const url = vdsAssetUrl('js/bootstrap5-theme.min.js', localhost)
49
73
  return <script type="text/javascript" src={url}></script>
50
74
  }
51
75
 
52
- export function VdsLogo({locale, disposition = "default", size = '17', tagline = true, dark = false}) {
76
+ export function VdsLogo({
77
+ locale,
78
+ disposition = 'default',
79
+ size = '17',
80
+ tagline = true,
81
+ dark = false
82
+ }) {
53
83
  locale = fixLocale(locale)
54
84
  let trans = i18n[locale] || i18n.en
55
85
 
56
- if (disposition == "mobile") {
57
- disposition = "left-two-lines"
86
+ if (disposition == 'mobile') {
87
+ disposition = 'left-two-lines'
58
88
  tagline = false
59
89
  }
60
90
 
61
- return <div className="vipassana-logo"
91
+ return (
92
+ <div
93
+ className="vipassana-logo"
62
94
  data-lang={locale}
63
95
  data-disposition={disposition}
64
96
  data-tagline={tagline}
65
97
  data-dark-mode={dark}
66
98
  data-reverse={trans.reverse}
67
- style={{fontSize: `${size}px`}}>
68
- <img className="logo-wheel" src="https://design-standards.dhamma.org/dist/dhamma-wheel.svg" />
69
- <div className="logo-text">
70
- <h1 className="logo-title">
71
- <span data-start-with={trans.vipassana_meditation.charAt(0).toLowerCase()}>
72
- {trans.vipassana_meditation}
73
- </span>
74
- <span className="logo-space">&nbsp;</span>
75
- <span>{trans.as_taught}</span>
76
- <span className="vipassana-as-taught">{trans.vipassana_as_taught}</span>
77
- </h1>
78
- <div className="logo-subtitle">{trans.in_the_tradition}</div>
99
+ style={{ fontSize: `${size}px` }}
100
+ >
101
+ <img className="logo-wheel" src="https://design-standards.dhamma.org/dist/dhamma-wheel.svg" />
102
+ <div className="logo-text">
103
+ <h1 className="logo-title">
104
+ <span data-start-with={trans.vipassana_meditation.charAt(0).toLowerCase()}>
105
+ {trans.vipassana_meditation}
106
+ </span>
107
+ <span className="logo-space">&nbsp;</span>
108
+ <span>{trans.as_taught}</span>
109
+ <span className="vipassana-as-taught">{trans.vipassana_as_taught}</span>
110
+ </h1>
111
+ <div className="logo-subtitle">{trans.in_the_tradition}</div>
112
+ </div>
79
113
  </div>
80
- </div>
114
+ )
81
115
  }
82
116
 
83
117
  // Some icons from bootstrap icons, so all websites use the same
84
- export function VdsIconLocale({size = 1.2}) {
85
- return <svg xmlns="http://www.w3.org/2000/svg" width={`${size}em`} height={`${size}em`} fill="currentColor" viewBox="0 0 16 16">
86
- <path d="M4.545 6.714 4.11 8H3l1.862-5h1.284L8 8H6.833l-.435-1.286H4.545zm1.634-.736L5.5 3.956h-.049l-.679 2.022H6.18z"/>
87
- <path d="M0 2a2 2 0 0 1 2-2h7a2 2 0 0 1 2 2v3h3a2 2 0 0 1 2 2v7a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2v-3H2a2 2 0 0 1-2-2V2zm2-1a1 1 0 0 0-1 1v7a1 1 0 0 0 1 1h7a1 1 0 0 0 1-1V2a1 1 0 0 0-1-1H2zm7.138 9.995c.193.301.402.583.63.846-.748.575-1.673 1.001-2.768 1.292.178.217.451.635.555.867 1.125-.359 2.08-.844 2.886-1.494.777.665 1.739 1.165 2.93 1.472.133-.254.414-.673.629-.89-1.125-.253-2.057-.694-2.82-1.284.681-.747 1.222-1.651 1.621-2.757H14V8h-3v1.047h.765c-.318.844-.74 1.546-1.272 2.13a6.066 6.066 0 0 1-.415-.492 1.988 1.988 0 0 1-.94.31z"/>
88
- </svg>
118
+ export function VdsIconLocale({ size = 1.2 }) {
119
+ return (
120
+ <svg
121
+ xmlns="http://www.w3.org/2000/svg"
122
+ width={`${size}em`}
123
+ height={`${size}em`}
124
+ fill="currentColor"
125
+ viewBox="0 0 16 16"
126
+ >
127
+ <path d="M4.545 6.714 4.11 8H3l1.862-5h1.284L8 8H6.833l-.435-1.286H4.545zm1.634-.736L5.5 3.956h-.049l-.679 2.022H6.18z" />
128
+ <path d="M0 2a2 2 0 0 1 2-2h7a2 2 0 0 1 2 2v3h3a2 2 0 0 1 2 2v7a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2v-3H2a2 2 0 0 1-2-2V2zm2-1a1 1 0 0 0-1 1v7a1 1 0 0 0 1 1h7a1 1 0 0 0 1-1V2a1 1 0 0 0-1-1H2zm7.138 9.995c.193.301.402.583.63.846-.748.575-1.673 1.001-2.768 1.292.178.217.451.635.555.867 1.125-.359 2.08-.844 2.886-1.494.777.665 1.739 1.165 2.93 1.472.133-.254.414-.673.629-.89-1.125-.253-2.057-.694-2.82-1.284.681-.747 1.222-1.651 1.621-2.757H14V8h-3v1.047h.765c-.318.844-.74 1.546-1.272 2.13a6.066 6.066 0 0 1-.415-.492 1.988 1.988 0 0 1-.94.31z" />
129
+ </svg>
130
+ )
89
131
  }
90
132
 
91
- export function VdsIconAccount({size = 2.2}) {
92
- return <svg xmlns="http://www.w3.org/2000/svg" width={`${size}em`} height={`${size}em`} fill="currentColor" viewBox="0 0 16 16">
93
- <path d="M11 6a3 3 0 1 1-6 0 3 3 0 0 1 6 0z"/>
94
- <path fillRule="evenodd" d="M0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8zm8-7a7 7 0 0 0-5.468 11.37C3.242 11.226 4.805 10 8 10s4.757 1.225 5.468 2.37A7 7 0 0 0 8 1z"/>
95
- </svg>
133
+ export function VdsIconAccount({ size = 2.2 }) {
134
+ return (
135
+ <svg
136
+ xmlns="http://www.w3.org/2000/svg"
137
+ width={`${size}em`}
138
+ height={`${size}em`}
139
+ fill="currentColor"
140
+ viewBox="0 0 16 16"
141
+ >
142
+ <path d="M11 6a3 3 0 1 1-6 0 3 3 0 0 1 6 0z" />
143
+ <path
144
+ fillRule="evenodd"
145
+ d="M0 8a8 8 0 1 1 16 0A8 8 0 0 1 0 8zm8-7a7 7 0 0 0-5.468 11.37C3.242 11.226 4.805 10 8 10s4.757 1.225 5.468 2.37A7 7 0 0 0 8 1z"
146
+ />
147
+ </svg>
148
+ )
96
149
  }
97
150
 
98
- export function VdsIconMenu({size = 1.8}) {
99
- return <svg xmlns="http://www.w3.org/2000/svg" width={`${size}em`} height={`${size}em`} fill="currentColor" viewBox="0 0 16 16">
100
- <path fillRule="evenodd" d="M2.5 12a.5.5 0 0 1 .5-.5h10a.5.5 0 0 1 0 1H3a.5.5 0 0 1-.5-.5zm0-4a.5.5 0 0 1 .5-.5h10a.5.5 0 0 1 0 1H3a.5.5 0 0 1-.5-.5zm0-4a.5.5 0 0 1 .5-.5h10a.5.5 0 0 1 0 1H3a.5.5 0 0 1-.5-.5z"/>
101
- </svg>
151
+ export function VdsIconMenu({ size = 1.8 }) {
152
+ return (
153
+ <svg
154
+ xmlns="http://www.w3.org/2000/svg"
155
+ width={`${size}em`}
156
+ height={`${size}em`}
157
+ fill="currentColor"
158
+ viewBox="0 0 16 16"
159
+ >
160
+ <path
161
+ fillRule="evenodd"
162
+ d="M2.5 12a.5.5 0 0 1 .5-.5h10a.5.5 0 0 1 0 1H3a.5.5 0 0 1-.5-.5zm0-4a.5.5 0 0 1 .5-.5h10a.5.5 0 0 1 0 1H3a.5.5 0 0 1-.5-.5zm0-4a.5.5 0 0 1 .5-.5h10a.5.5 0 0 1 0 1H3a.5.5 0 0 1-.5-.5z"
163
+ />
164
+ </svg>
165
+ )
102
166
  }
package/package.json CHANGED
@@ -1,12 +1,20 @@
1
1
  {
2
2
  "name": "vipassana-design-standards",
3
- "version": "0.0.37",
3
+ "version": "1.1.0",
4
4
  "description": "Vipassana design standards materials",
5
5
  "homepage": "https://design-standards.dhamma.org",
6
6
  "author": "Dhamma Workers",
7
7
  "dependencies": {
8
8
  "@popperjs/core": "^2.9.1",
9
- "bootstrap5": "npm:bootstrap@5"
9
+ "bootstrap5": "npm:bootstrap@5.2.3"
10
+ },
11
+ "devDependencies": {
12
+ "@babel/cli": "^7.24.1",
13
+ "@babel/core": "^7.24.4",
14
+ "@babel/preset-env": "^7.24.4",
15
+ "@babel/preset-react": "^7.24.1",
16
+ "react": "^18.2.0",
17
+ "react-dom": "^18.2.0"
10
18
  },
11
19
  "files": [
12
20
  "dist/js",
@@ -24,7 +32,7 @@
24
32
  "build-css": "rm -f dist/css/* && npm run build-fonts && npm run build-logo && npm run build-sass && npm run build-rtl && npm run build-min",
25
33
  "build-js": "rm -f dist/js/* && npm run build-js-bootstrap && npm run build-js-helper",
26
34
  "build-js-bootstrap": "concat -o dist/js/bootstrap5-theme.min.js node_modules/bootstrap5/dist/js/bootstrap.bundle.min.js src/javascripts/auto-resize.js && cp node_modules/bootstrap5/dist/js/bootstrap.bundle.min.js.map dist/js/bootstrap5-theme.min.js.map",
27
- "build-js-helper": "cp src/javascripts/helpers.js dist/js && cp src/javascripts/react-helpers.jsx dist/js && cp src/javascripts/i18n.js dist/js && node replace-version.js",
35
+ "build-js-helper": "cp src/javascripts/helpers.js dist/js && cp src/javascripts/react-helpers.jsx dist/js && cp src/javascripts/i18n.js dist/js && node replace-version.js && npx babel dist/js/react-helpers.jsx --out-file dist/js/react-helpers.js",
28
36
  "build": "npm run build-css && npm run build-js",
29
37
  "dist": "npm run build && npm run dist-version-folder && npm publish && npm run dist-gem",
30
38
  "dist-gem": "gem build vipassana-design-standards.gemspec && gem push vipassana-design-standards-$npm_package_version.gem && rm vipassana-design-standards-$npm_package_version.gem",
@@ -1,17 +1,17 @@
1
- @import "./custom-bootstrap-variables.scss";
1
+ @import './custom-bootstrap-variables.scss';
2
2
 
3
- @import "bootstrap5/scss/bootstrap.scss";
3
+ @import 'bootstrap5/scss/bootstrap.scss';
4
4
 
5
- @import "./custom-bootstrap-utilities.scss";
6
- @import "./custom-bootstrap.scss";
5
+ @import './custom-bootstrap-utilities.scss';
6
+ @import './custom-bootstrap.scss';
7
7
 
8
- @import "./layout/vds-mixins.scss";
9
- @import "./layout/vds-layout.scss";
10
- @import "./layout/vds-header.scss";
11
- @import "./layout/vds-sidenav.scss";
8
+ @import './layout/vds-mixins.scss';
9
+ @import './layout/vds-layout.scss';
10
+ @import './layout/vds-header.scss';
11
+ @import './layout/vds-sidenav.scss';
12
12
 
13
- @import "./fonts.scss";
14
- @import "./logo.scss";
13
+ @import './fonts.scss';
14
+ @import './logo.scss';
15
15
 
16
16
  html.vds-html {
17
17
  font-size: 13.5px;
@@ -21,4 +21,4 @@ html.vds-html {
21
21
  @include media-breakpoint-up(xl) {
22
22
  font-size: 15.3px;
23
23
  }
24
- }
24
+ }
@@ -1,4 +1,3 @@
1
-
2
1
  :root {
3
2
  // Generate missing CSS Variables
4
3
  @each $color, $value in $blues {
@@ -54,56 +53,136 @@
54
53
  }
55
54
 
56
55
  // fs-09-rem, fs-085-em..
57
- .fs-05-rem { font-size: .5rem !important; }
58
- .fs-05-em { font-size: .5em !important; }
59
- .fs-055-rem { font-size: .55rem !important; }
60
- .fs-055-em { font-size: .55em !important; }
61
-
62
- .fs-06-rem { font-size: .6rem !important; }
63
- .fs-06-em { font-size: .6em !important; }
64
- .fs-065-rem { font-size: .65rem !important; }
65
- .fs-065-em { font-size: .65em !important; }
66
-
67
- .fs-07-rem { font-size: .7rem !important; }
68
- .fs-07-em { font-size: .7em !important; }
69
- .fs-075-rem { font-size: .75rem !important; }
70
- .fs-075-em { font-size: .75em !important; }
71
-
72
- .fs-08-rem { font-size: .8rem !important; }
73
- .fs-08-em { font-size: .8em !important; }
74
- .fs-085-rem { font-size: .85rem !important; }
75
- .fs-085-em { font-size: .85em !important; }
76
-
77
- .fs-09-rem { font-size: .9rem !important; }
78
- .fs-09-em { font-size: .9em !important; }
79
- .fs-095-rem { font-size: .95rem !important; }
80
- .fs-095-em { font-size: .95em !important; }
56
+ .fs-05-rem {
57
+ font-size: 0.5rem !important;
58
+ }
59
+ .fs-05-em {
60
+ font-size: 0.5em !important;
61
+ }
62
+ .fs-055-rem {
63
+ font-size: 0.55rem !important;
64
+ }
65
+ .fs-055-em {
66
+ font-size: 0.55em !important;
67
+ }
68
+
69
+ .fs-06-rem {
70
+ font-size: 0.6rem !important;
71
+ }
72
+ .fs-06-em {
73
+ font-size: 0.6em !important;
74
+ }
75
+ .fs-065-rem {
76
+ font-size: 0.65rem !important;
77
+ }
78
+ .fs-065-em {
79
+ font-size: 0.65em !important;
80
+ }
81
+
82
+ .fs-07-rem {
83
+ font-size: 0.7rem !important;
84
+ }
85
+ .fs-07-em {
86
+ font-size: 0.7em !important;
87
+ }
88
+ .fs-075-rem {
89
+ font-size: 0.75rem !important;
90
+ }
91
+ .fs-075-em {
92
+ font-size: 0.75em !important;
93
+ }
94
+
95
+ .fs-08-rem {
96
+ font-size: 0.8rem !important;
97
+ }
98
+ .fs-08-em {
99
+ font-size: 0.8em !important;
100
+ }
101
+ .fs-085-rem {
102
+ font-size: 0.85rem !important;
103
+ }
104
+ .fs-085-em {
105
+ font-size: 0.85em !important;
106
+ }
107
+
108
+ .fs-09-rem {
109
+ font-size: 0.9rem !important;
110
+ }
111
+ .fs-09-em {
112
+ font-size: 0.9em !important;
113
+ }
114
+ .fs-095-rem {
115
+ font-size: 0.95rem !important;
116
+ }
117
+ .fs-095-em {
118
+ font-size: 0.95em !important;
119
+ }
81
120
 
82
121
  // fs-11-rem, fs-125-em...
83
- .fs-11-rem { font-size: 1.1rem !important; }
84
- .fs-11-em { font-size: 1.1em !important; }
85
- .fs-115-rem { font-size: 1.15rem !important; }
86
- .fs-115-em { font-size: 1.15em !important; }
87
-
88
- .fs-12-rem { font-size: 1.2rem !important; }
89
- .fs-12-em { font-size: 1.2em !important; }
90
- .fs-125-rem { font-size: 1.25rem !important; }
91
- .fs-125-em { font-size: 1.25em !important; }
92
-
93
- .fs-13-rem { font-size: 1.3rem !important; }
94
- .fs-13-em { font-size: 1.3em !important; }
95
- .fs-135-rem { font-size: 1.35rem !important; }
96
- .fs-135-em { font-size: 1.35em !important; }
97
-
98
- .fs-14-rem { font-size: 1.4rem !important; }
99
- .fs-14-em { font-size: 1.4em !important; }
100
- .fs-145-rem { font-size: 1.45rem !important; }
101
- .fs-145-em { font-size: 1.45em !important; }
102
-
103
- .fs-15-rem { font-size: 1.5rem !important; }
104
- .fs-15-em { font-size: 1.5em !important; }
105
- .fs-155-rem { font-size: 1.55rem !important; }
106
- .fs-155-em { font-size: 1.55em !important; }
122
+ .fs-11-rem {
123
+ font-size: 1.1rem !important;
124
+ }
125
+ .fs-11-em {
126
+ font-size: 1.1em !important;
127
+ }
128
+ .fs-115-rem {
129
+ font-size: 1.15rem !important;
130
+ }
131
+ .fs-115-em {
132
+ font-size: 1.15em !important;
133
+ }
134
+
135
+ .fs-12-rem {
136
+ font-size: 1.2rem !important;
137
+ }
138
+ .fs-12-em {
139
+ font-size: 1.2em !important;
140
+ }
141
+ .fs-125-rem {
142
+ font-size: 1.25rem !important;
143
+ }
144
+ .fs-125-em {
145
+ font-size: 1.25em !important;
146
+ }
147
+
148
+ .fs-13-rem {
149
+ font-size: 1.3rem !important;
150
+ }
151
+ .fs-13-em {
152
+ font-size: 1.3em !important;
153
+ }
154
+ .fs-135-rem {
155
+ font-size: 1.35rem !important;
156
+ }
157
+ .fs-135-em {
158
+ font-size: 1.35em !important;
159
+ }
160
+
161
+ .fs-14-rem {
162
+ font-size: 1.4rem !important;
163
+ }
164
+ .fs-14-em {
165
+ font-size: 1.4em !important;
166
+ }
167
+ .fs-145-rem {
168
+ font-size: 1.45rem !important;
169
+ }
170
+ .fs-145-em {
171
+ font-size: 1.45em !important;
172
+ }
173
+
174
+ .fs-15-rem {
175
+ font-size: 1.5rem !important;
176
+ }
177
+ .fs-15-em {
178
+ font-size: 1.5em !important;
179
+ }
180
+ .fs-155-rem {
181
+ font-size: 1.55rem !important;
182
+ }
183
+ .fs-155-em {
184
+ font-size: 1.55em !important;
185
+ }
107
186
 
108
187
  .full-width-sm {
109
188
  @include media-breakpoint-down(md) {
@@ -139,4 +218,4 @@
139
218
  padding: 2rem;
140
219
  z-index: 500;
141
220
  }
142
- }
221
+ }