@appartmint/mint 0.8.13 → 0.9.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 (57) hide show
  1. package/dist/css/mint.css +155 -1
  2. package/dist/css/mint.css.map +1 -1
  3. package/dist/css/mint.min.css +1 -1
  4. package/dist/css/mint.min.css.map +1 -1
  5. package/dist/css/noscript.css +8 -0
  6. package/dist/css/noscript.css.map +1 -0
  7. package/dist/css/noscript.min.css +3 -0
  8. package/dist/css/noscript.min.css.map +1 -0
  9. package/dist/js/imports/components/header.d.ts +110 -0
  10. package/dist/js/imports/components/header.d.ts.map +1 -0
  11. package/dist/js/imports/enum.d.ts +10 -0
  12. package/dist/js/imports/enum.d.ts.map +1 -0
  13. package/dist/js/imports/models/color.d.ts +32 -0
  14. package/dist/js/imports/models/color.d.ts.map +1 -0
  15. package/dist/js/imports/models/item.d.ts +48 -0
  16. package/dist/js/imports/models/item.d.ts.map +1 -0
  17. package/dist/js/imports/util/display.d.ts +7 -0
  18. package/dist/js/imports/util/display.d.ts.map +1 -0
  19. package/dist/js/imports/util/event.d.ts +7 -0
  20. package/dist/js/imports/util/event.d.ts.map +1 -0
  21. package/dist/js/imports/util/icon.d.ts +24 -0
  22. package/dist/js/imports/util/icon.d.ts.map +1 -0
  23. package/dist/js/imports/util/math.d.ts +14 -0
  24. package/dist/js/imports/util/math.d.ts.map +1 -0
  25. package/dist/js/imports/util/object.d.ts +59 -0
  26. package/dist/js/imports/util/object.d.ts.map +1 -0
  27. package/dist/js/imports/util/selectors.d.ts +146 -0
  28. package/dist/js/imports/util/selectors.d.ts.map +1 -0
  29. package/dist/js/imports/util/settings.d.ts +53 -0
  30. package/dist/js/imports/util/settings.d.ts.map +1 -0
  31. package/dist/js/imports/util/text.d.ts +7 -0
  32. package/dist/js/imports/util/text.d.ts.map +1 -0
  33. package/dist/js/imports/util/window.d.ts +7 -0
  34. package/dist/js/imports/util/window.d.ts.map +1 -0
  35. package/dist/js/index.d.ts +19 -2
  36. package/dist/js/index.d.ts.map +1 -1
  37. package/dist/js/index.js +1505 -80
  38. package/dist/js/index.js.map +1 -1
  39. package/dist/js/index.min.js +1 -1
  40. package/dist/js/index.min.js.map +1 -1
  41. package/dist/js/util.d.ts +78 -0
  42. package/dist/js/util.d.ts.map +1 -0
  43. package/dist/js/util.js +638 -0
  44. package/dist/js/util.js.map +1 -0
  45. package/dist/js/util.min.js +2 -0
  46. package/dist/js/util.min.js.map +1 -0
  47. package/package.json +1 -5
  48. package/src/scss/imports/components/_buttons.scss +1 -0
  49. package/src/scss/imports/components/_header.scss +196 -0
  50. package/src/scss/imports/components/_index.scss +2 -1
  51. package/src/scss/imports/global/_global.scss +5 -1
  52. package/src/scss/imports/global/_themes.scss +0 -1
  53. package/src/scss/imports/{_mint.scss → util/_index.scss} +1 -1
  54. package/src/scss/imports/util/_util.scss +713 -0
  55. package/src/scss/noscript.scss +14 -0
  56. package/src/scss/imports/_util.scss +0 -7
  57. /package/src/scss/imports/{_vars.scss → util/_vars.scss} +0 -0
@@ -0,0 +1,146 @@
1
+ /**
2
+ * CSS-selector helpers
3
+ * @public
4
+ */
5
+ export declare abstract class mintSelectors {
6
+ /**
7
+ * The library name that will be added as a prefix
8
+ */
9
+ static lib: string;
10
+ /**
11
+ * The prefix built from the library name
12
+ */
13
+ static pre: string;
14
+ /**
15
+ * CSS-selector for disabled elements
16
+ */
17
+ static disabled: string;
18
+ /**
19
+ * CSS-selector for elements with an aria-controls attribute
20
+ */
21
+ static hasControls: string;
22
+ /**
23
+ * CSS-selector for elements with an aria-expanded attribute
24
+ */
25
+ static hasExpanded: string;
26
+ /**
27
+ * CSS-selector for elements with an href attribute
28
+ */
29
+ static hasLink: string;
30
+ /**
31
+ * CSS-selector for elements with a routerLink attribute
32
+ */
33
+ static hasRouterLink: string;
34
+ /**
35
+ * CSS-selector for elements with an id attribute
36
+ */
37
+ static hasId: string;
38
+ /**
39
+ * CSS-selector for elements that aren't tabbable (i.e. tabindex is negative)
40
+ */
41
+ static notTabbable: string;
42
+ /**
43
+ * CSS-selector for elements that are tabbable (i.e. tabindex isn't negative)
44
+ */
45
+ static tabbable: string;
46
+ /**
47
+ * CSS-selector for elements that can receive focus
48
+ */
49
+ static focusable: string;
50
+ /**
51
+ * CSS-selector for submenu buttons
52
+ */
53
+ static subMenuButtons: string;
54
+ /**
55
+ * CSS-selector for submenus
56
+ */
57
+ static subMenu: string;
58
+ /**
59
+ * Frequently-used ids
60
+ */
61
+ static ids: {
62
+ [key: string]: string | {
63
+ [key: string]: string;
64
+ };
65
+ };
66
+ /**
67
+ * Classes
68
+ */
69
+ static classes: {
70
+ [key: string]: string | {
71
+ [key: string]: string;
72
+ };
73
+ };
74
+ /**
75
+ * Adds the library prefix to the beginning of the provided string
76
+ * @param base - the string to be prefixed
77
+ * @returns - the provided string prefixed with the library name
78
+ */
79
+ static prefix(base: string): string;
80
+ /**
81
+ * Adds two dashes to the beginning of the provided string
82
+ * @param base - the string to be prefixed
83
+ * @returns - the provided string prefixed with two dashes
84
+ */
85
+ static cssPrefix(base: string): string;
86
+ /**
87
+ * Turns the provided string into a CSS variable call
88
+ * @param base - the name of the CSS variable to call
89
+ * @returns - the CSS variable call for the provided string
90
+ */
91
+ static cssVar(base: string): string;
92
+ /**
93
+ * Negates the provided CSS selector
94
+ * @param base - the CSS selector to negate
95
+ * @returns - the negated CSS selector
96
+ */
97
+ static neg(base: string): string;
98
+ /**
99
+ * Generates a class CSS selector
100
+ * @param base - the name of the class to generate
101
+ * @returns - the generated CSS selector
102
+ */
103
+ static class(base: string): string;
104
+ /**
105
+ * Generates an id CSS selector
106
+ * @param base - the name of the id to generate
107
+ * @returns - the generated CSS selector
108
+ */
109
+ static id(base: string): string;
110
+ /**
111
+ * Generates an aria-controls CSS selector
112
+ * @param id - the id of the controlled element
113
+ * @returns - the generated CSS selector
114
+ */
115
+ static controls(id?: string | null): string;
116
+ /**
117
+ * Generates an aria-expanded CSS selector
118
+ * @param bool - whether the element is expanded or not
119
+ * @returns - the generated CSS selector
120
+ */
121
+ static expanded(bool?: boolean | null): string;
122
+ /**
123
+ * Returns the id of the requested element
124
+ */
125
+ static getId(id?: string): string;
126
+ /**
127
+ * Returns the class of the requested element
128
+ */
129
+ static getClass(className?: string, classGroup?: string): string;
130
+ /**
131
+ * Returns a NodeList of HTMLElements within the given element that are focusable
132
+ * @param el - the element whose focusable children will be returned
133
+ * @returns - the elements within the given element that are focusable
134
+ */
135
+ static getFocusables(el?: HTMLElement): HTMLElement[];
136
+ /**
137
+ * Returns true if an element is focusable and false if not,
138
+ * based on styles (i.e. a parent has display: none;)
139
+ * NOTE: Still need to determine what other styles may make an element un-focusable
140
+ * @param el - the element
141
+ * @returns - true if the element is focusable; false if not
142
+ */
143
+ static isFocusable(el: HTMLElement): boolean;
144
+ }
145
+ export default mintSelectors;
146
+ //# sourceMappingURL=selectors.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"selectors.d.ts","sourceRoot":"","sources":["../../../../src/ts/imports/util/selectors.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,8BAAsB,aAAa;IAC/B;;OAEG;IACH,MAAM,CAAC,GAAG,EAAE,MAAM,CAAU;IAE5B;;OAEG;IACH,MAAM,CAAC,GAAG,EAAE,MAAM,CAAkB;IAEpC;;OAEG;IACH,MAAM,CAAC,QAAQ,EAAE,MAAM,CAAgB;IAEvC;;OAEG;IACH,MAAM,CAAC,WAAW,EAAE,MAAM,CAAqB;IAE/C;;OAEG;IACH,MAAM,CAAC,WAAW,EAAE,MAAM,CAAqB;IAE/C;;OAEG;IACH,MAAM,CAAC,OAAO,EAAE,MAAM,CAAY;IAElC;;OAEG;IACH,MAAM,CAAC,aAAa,EAAE,MAAM,CAAkB;IAE9C;;OAEG;IACH,MAAM,CAAC,KAAK,EAAE,MAAM,CAAU;IAE9B;;OAEG;IACH,MAAM,CAAC,WAAW,EAAE,MAAM,CAAqB;IAE/C;;OAEG;IACH,MAAM,CAAC,Q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M,GAAI,MAAM;IAInC;;OAEG;IACH,MAAM,CAAC,QAAQ,CAAE,SAAS,CAAC,EAAE,MAAM,EAAE,UAAU,CAAC,EAAE,MAAM,GAAI,MAAM;IAQlE;;;;OAIG;IACH,MAAM,CAAC,aAAa,CAAE,EAAE,CAAC,EAAE,WAAW,GAAI,WAAW,EAAE;IAUvD;;;;;;OAMG;IACH,MAAM,CAAC,WAAW,CAAE,EAAE,EAAE,WAAW,GAAI,OAAO;CAWjD;AACD,eAAe,aAAa,CAAC"}
@@ -0,0 +1,53 @@
1
+ /**
2
+ * Imports
3
+ */
4
+ import { mintSide } from '../enum';
5
+ /**
6
+ * Settings management
7
+ * @public
8
+ */
9
+ export declare abstract class mintSettings {
10
+ /**
11
+ * Value added to all delay variables
12
+ */
13
+ static delayBase: number;
14
+ /**
15
+ * Value multiplied by delay variable index
16
+ */
17
+ static delayStep: number;
18
+ /**
19
+ * Delay variables
20
+ */
21
+ static delay: {
22
+ [key: string]: number;
23
+ };
24
+ /**
25
+ * Side of the window the mobile navbar enters from
26
+ */
27
+ static from?: mintSide;
28
+ /**
29
+ * Whether the navbar is fixed or not
30
+ */
31
+ static fixed?: boolean;
32
+ /**
33
+ * Update the provided settings variables
34
+ * @param settings - Object of settings variables to update
35
+ */
36
+ static set(settings: {
37
+ [key: string]: any;
38
+ }): void;
39
+ /**
40
+ * Updates the delay variables based on `this.delayBase` and `this.delayStep`
41
+ */
42
+ protected static setDelay(): void;
43
+ /**
44
+ * Updates the direction the navbar enters from
45
+ */
46
+ protected static setFrom(from: mintSide): void;
47
+ /**
48
+ * Updates whether or not the navbar is fixed
49
+ */
50
+ protected static setFixed(fixed: boolean): void;
51
+ }
52
+ export default mintSettings;
53
+ //# sourceMappingURL=settings.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"settings.d.ts","sourceRoot":"","sources":["../../../../src/ts/imports/util/settings.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAGnC;;;GAGG;AACH,8BAAsB,YAAY;IAC9B;;OAEG;IACH,MAAM,CAAC,SAAS,EAAE,MAAM,CAAK;IAE7B;;OAEG;IACH,MAAM,CAAC,SAAS,EAAE,MAAM,CAAO;IAE/B;;OAEG;IACH,MAAM,CAAC,KAAK,EAAE;QAAC,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;KAAC,CAOnC;IAEF;;OAEG;IACH,MAAM,CAAC,IAAI,CAAC,EAAE,QAAQ,CAAC;IAEvB;;MAEE;IACD,MAAM,CAAC,KAAK,CAAC,EAAE,OAAO,CAAC;IAExB;;;OAGG;IACH,MAAM,CAAC,GAAG,CAAE,QAAQ,EAAE;QAAC,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KAAC,GAAI,IAAI;IAqBlD;;OAEG;IACH,SAAS,CAAC,MAAM,CAAC,QAAQ,IAAM,IAAI;IAWnC;;OAEG;IACH,SAAS,CAAC,MAAM,CAAC,OAAO,CAAE,IAAI,EAAE,QAAQ,GAAI,IAAI;IAShD;;OAEG;IACH,SAAS,CAAC,MAAM,CAAC,QAAQ,CAAE,KAAK,EAAE,OAAO,GAAI,IAAI;CAYpD;AAED,eAAe,YAAY,CAAC"}
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Functions for analyzing and manipulating text.
3
+ */
4
+ export declare abstract class mintText {
5
+ }
6
+ export default mintText;
7
+ //# sourceMappingURL=text.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"text.d.ts","sourceRoot":"","sources":["../../../../src/ts/imports/util/text.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,8BAAsB,QAAQ;CAa7B;AACD,eAAe,QAAQ,CAAC"}
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Functions related to the browser window.
3
+ */
4
+ export declare abstract class mintWindow {
5
+ }
6
+ export default mintWindow;
7
+ //# sourceMappingURL=window.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"window.d.ts","sourceRoot":"","sources":["../../../../src/ts/imports/util/window.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,8BAAsB,UAAU;CAE/B;AACD,eAAe,UAAU,CAAC"}
@@ -1,6 +1,23 @@
1
+ /**
2
+ * A library for building responsive web applications.
3
+ *
4
+ * @packageDocumentation
5
+ */
1
6
  /**
2
7
  * Exports
3
8
  */
4
- export { n4vBar, n4vSelectors, n4vSettings } from '@appartmint/n4v';
5
- export { mintUtil, mintSelectors, mintSettings, mintColor, mintDisplay, mintEvent, mintObject, mintText, mintWindow, mintSide } from '@appartmint/util';
9
+ export { mintSide } from './imports/enum';
10
+ export { mintHeader } from './imports/components/header';
11
+ export { mintColor } from './imports/models/color';
12
+ export { mintItem } from './imports/models/item';
13
+ export { mintDisplay } from './imports/util/display';
14
+ export { mintEvent } from './imports/util/event';
15
+ export { mintIcon } from './imports/util/icon';
16
+ export { mintMath } from './imports/util/math';
17
+ export { mintObject } from './imports/util/object';
18
+ export { mintText } from './imports/util/text';
19
+ export { mintWindow } from './imports/util/window';
20
+ export { mintSelectors } from './imports/util/selectors';
21
+ export { mintSettings } from './imports/util/settings';
22
+ export { mintUtil, default } from './util';
6
23
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/ts/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAGH,OAAO,EACH,MAAM,EACN,YAAY,EACZ,WAAW,EACd,MAAM,iBAAiB,CAAC;AAGzB,OAAO,EACH,QAAQ,EACR,aAAa,EACb,YAAY,EACZ,SAAS,EACT,WAAW,EACX,SAAS,EACT,UAAU,EACV,QAAQ,EACR,UAAU,EACV,QAAQ,EACX,MAAM,kBAAkB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/ts/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;GAEG;AAEH,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAG1C,OAAO,EAAE,UAAU,EAAE,MAAM,6BAA6B,CAAC;AAGzD,OAAO,EAAE,SAAS,EAAE,MAAM,wBAAwB,CAAC;AACnD,OAAO,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAGjD,OAAO,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AACrD,OAAO,EAAE,SAAS,EAAE,MAAM,sBAAsB,CAAC;AACjD,OAAO,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAC;AAC/C,OAAO,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AACnD,OAAO,EAAE,QAAQ,EAAE,MAAM,qBAAqB,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AAGnD,OAAO,EAAE,aAAa,EAAE,MAAM,0BAA0B,CAAC;AACzD,OAAO,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AACvD,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,QAAQ,CAAC"}