@esportsplus/ui 0.0.15 → 0.0.17

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.
@@ -1,4 +1,5 @@
1
1
  import header from './header';
2
+ import layout from './layout';
2
3
  declare const _default: {
3
4
  header: ({ subtitle, suptitle, title }: {
4
5
  subtitle?: string | undefined;
@@ -9,6 +10,14 @@ declare const _default: {
9
10
  type: string;
10
11
  values: never[];
11
12
  };
13
+ layout: (data?: {
14
+ class?: string | undefined;
15
+ content?: any;
16
+ }) => {
17
+ content: string;
18
+ type: string;
19
+ values: never[];
20
+ };
12
21
  };
13
22
  export default _default;
14
- export { header };
23
+ export { header, layout };
@@ -1,3 +1,4 @@
1
1
  import header from './header';
2
- export default { header };
3
- export { header };
2
+ import layout from './layout';
3
+ export default { header, layout };
4
+ export { header, layout };
@@ -1,11 +1,8 @@
1
1
  type Data = {
2
+ class?: string;
2
3
  content?: any;
3
- subtitle?: string;
4
- suptitle?: string;
5
- title?: string;
6
- width?: string;
7
4
  };
8
- declare const _default: ({ content, subtitle, suptitle, title, width }: Data) => {
5
+ declare const _default: (data?: Data) => {
9
6
  content: string;
10
7
  type: string;
11
8
  values: never[];
@@ -1,24 +1,6 @@
1
1
  import { html } from '@esportsplus/template';
2
- export default ({ content, subtitle, suptitle, title, width }) => html `
3
- <div class="container --slide-in --margin-vertical --margin-900" style="${width && `--max-width: ${width};`}">
4
- ${suptitle ? html `
5
- <span class="page-suptitle --text-bold --text-crop --text-uppercase --text-200" style="--color-default: var(--color-primary-400);letter-spacing: 0.24px;">
6
- ${suptitle}
7
- </span>
8
- ` : ''}
9
-
10
- ${title ? html `
11
- <h1 class="page-title --line-height-200 --margin-300 ${!subtitle && '--text-crop-bottom'} ${suptitle ? '--margin-top' : '--text-crop-top'}">
12
- ${title}
13
- </h1>
14
- ` : ''}
15
-
16
- ${subtitle ? html `
17
- <span class="page-subtitle --margin-top --margin-300 --text-crop-bottom">
18
- ${subtitle}
19
- </span>
20
- ` : ''}
21
-
22
- ${content || ''}
23
- </div>
2
+ export default (data = {}) => html `
3
+ <section class='page ${data?.class}'>
4
+ ${data?.content}
5
+ </section>
24
6
  `;
@@ -1,23 +1 @@
1
- declare const _default: {
2
- layout: (data?: {
3
- anchor?: {
4
- content?: any;
5
- } | undefined;
6
- content?: any;
7
- page?: {
8
- class?: string | undefined;
9
- content?: any;
10
- } | undefined;
11
- scrollbar?: {
12
- style?: string | undefined;
13
- } | undefined;
14
- site?: {
15
- content?: any;
16
- } | undefined;
17
- }) => {
18
- content: string;
19
- type: string;
20
- values: never[];
21
- };
22
- };
23
- export default _default;
1
+ export { default as layout } from './layout';
@@ -1,2 +1 @@
1
- import layout from './layout';
2
- export default { layout };
1
+ export { default as layout } from './layout';
@@ -1,17 +1,14 @@
1
1
  type Data = {
2
- anchor?: {
3
- content?: any;
4
- };
5
- content?: any;
6
- page?: {
2
+ overlay?: {
7
3
  class?: string;
8
4
  content?: any;
9
5
  };
10
- scrollbar?: {
11
- style?: string;
12
- };
13
6
  site?: {
7
+ class?: string;
14
8
  content?: any;
9
+ scrollbar?: {
10
+ style?: string;
11
+ };
15
12
  };
16
13
  };
17
14
  declare const _default: (data?: Data) => {
@@ -1,25 +1,18 @@
1
1
  import { html } from '@esportsplus/template';
2
- import { alert, scrollbar } from '../../components';
2
+ import { scrollbar } from '../../components';
3
3
  export default (data = {}) => {
4
- let bar = scrollbar({
4
+ let s = scrollbar({
5
5
  fixed: true,
6
- style: data?.scrollbar?.style
6
+ style: data?.site?.scrollbar?.style || '--background-default: var(--color-black-400);'
7
7
  });
8
8
  return html `
9
- <section class='site' ${bar.attributes}>
10
- <section class='page --padding-horizontal --padding-horizontal-sidebars ${data?.page?.class}'>
11
- ${data?.page?.content}
12
- </section>
13
-
9
+ <section class='site ${data?.site?.class || ''}' ${s.attributes}>
14
10
  ${data?.site?.content || ''}
15
- ${bar.html}
11
+ ${s.html}
16
12
  </section>
17
13
 
18
- <section class='anchors'>
19
- ${alert.html()}
20
- ${data?.anchor?.content || ''}
14
+ <section class='overlay ${data?.overlay?.class || ''}'>
15
+ ${data?.overlay?.content || ''}
21
16
  </section>
22
-
23
- ${data?.content || ''}
24
17
  `;
25
18
  };
@@ -0,0 +1,5 @@
1
+ declare module '*.jpg';
2
+ declare module '*.json';
3
+ declare module '*.png';
4
+ declare module '*.svg';
5
+ declare module '*.txt';
@@ -0,0 +1 @@
1
+ "use strict";
package/build/index.d.ts CHANGED
@@ -1 +1,2 @@
1
+ import './types';
1
2
  export * from './components';
package/build/index.js CHANGED
@@ -1 +1,2 @@
1
+ import './types';
1
2
  export * from './components';
@@ -0,0 +1,5 @@
1
+ declare module '*.jpg';
2
+ declare module '*.json';
3
+ declare module '*.png';
4
+ declare module '*.svg';
5
+ declare module '*.txt';
package/build/types.js ADDED
@@ -0,0 +1 @@
1
+ "use strict";
package/index.scss ADDED
@@ -0,0 +1,2 @@
1
+ @forward './src/lib';
2
+ @forward './src/tokens';
package/package.json CHANGED
@@ -31,10 +31,10 @@
31
31
  "private": false,
32
32
  "scripts": {
33
33
  "build": "tsc && tsc-alias",
34
- "-": "-",
34
+ "--": "--",
35
35
  "prepare": "npm run build",
36
36
  "prepublishOnly": "npm run build"
37
37
  },
38
38
  "types": "./build/index.d.ts",
39
- "version": "0.0.15"
39
+ "version": "0.0.17"
40
40
  }
@@ -1,6 +1,6 @@
1
1
  @use '~@esportsplus/ui/lib';
2
2
 
3
- .anchors {
3
+ .overlay {
4
4
  @include lib.position(fixed, full);
5
5
  height: 100vh;
6
6
  pointer-events: none;
@@ -1,5 +1,6 @@
1
1
  import header from './header';
2
+ import layout from './layout';
2
3
 
3
4
 
4
- export default { header };
5
- export { header };
5
+ export default { header, layout };
6
+ export { header, layout };
@@ -0,0 +1,14 @@
1
+ import { html } from '@esportsplus/template';
2
+
3
+
4
+ type Data = {
5
+ class?: string;
6
+ content?: any;
7
+ };
8
+
9
+
10
+ export default (data: Data = {}) => html`
11
+ <section class='page ${data?.class}'>
12
+ ${data?.content}
13
+ </section>
14
+ `;
@@ -0,0 +1 @@
1
+ export { default as layout } from './layout';
@@ -0,0 +1,36 @@
1
+ import { html } from '@esportsplus/template';
2
+ import { scrollbar } from '~/components';
3
+
4
+
5
+ type Data = {
6
+ overlay?: {
7
+ class?: string;
8
+ content?: any;
9
+ };
10
+ site?: {
11
+ class?: string;
12
+ content?: any;
13
+ scrollbar?: {
14
+ style?: string;
15
+ };
16
+ };
17
+ };
18
+
19
+
20
+ export default (data: Data = {}) => {
21
+ let s = scrollbar({
22
+ fixed: true,
23
+ style: data?.site?.scrollbar?.style || '--background-default: var(--color-black-400);'
24
+ });
25
+
26
+ return html`
27
+ <section class='site ${data?.site?.class || ''}' ${s.attributes}>
28
+ ${data?.site?.content || ''}
29
+ ${s.html}
30
+ </section>
31
+
32
+ <section class='overlay ${data?.overlay?.class || ''}'>
33
+ ${data?.overlay?.content || ''}
34
+ </section>
35
+ `;
36
+ };
package/src/index.ts CHANGED
@@ -1 +1,4 @@
1
+ import './types';
2
+
3
+
1
4
  export * from './components';
package/src/types.ts ADDED
@@ -0,0 +1,5 @@
1
+ declare module '*.jpg';
2
+ declare module '*.json';
3
+ declare module '*.png';
4
+ declare module '*.svg';
5
+ declare module '*.txt';
package/lib.scss DELETED
@@ -1 +0,0 @@
1
- @forward 'src/lib';
@@ -1,13 +0,0 @@
1
- @use '~@esportsplus/ui/lib';
2
-
3
- .sidebars {
4
- @include lib.position(absolute, full);
5
- pointer-events: none;
6
- transition: opacity var(--transition-duration) ease-in-out;
7
- z-index: 7;
8
-
9
-
10
- &--fixed {
11
- position: fixed;
12
- }
13
- }
package/src/svg.d.ts DELETED
@@ -1,4 +0,0 @@
1
- declare module '*.svg' {
2
- const content: any;
3
- export default content;
4
- }
package/tokens.scss DELETED
@@ -1 +0,0 @@
1
- @forward 'src/tokens';