@digital-realty/ix-drawer 1.0.2 → 1.0.4
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.
package/dist/IxDrawer.d.ts
CHANGED
package/dist/IxDrawer.js
CHANGED
|
@@ -2,7 +2,6 @@ import { __decorate } from "tslib";
|
|
|
2
2
|
import { LitElement, html, nothing } from 'lit';
|
|
3
3
|
import { property } from 'lit/decorators.js';
|
|
4
4
|
import { IxDrawerStyles } from './styles/ix-drawer-styles.js';
|
|
5
|
-
import '@digital-realty/ix-button/ix-button.js';
|
|
6
5
|
import '@material/web/icon/icon.js';
|
|
7
6
|
export class IxDrawer extends LitElement {
|
|
8
7
|
constructor() {
|
|
@@ -15,6 +14,7 @@ export class IxDrawer extends LitElement {
|
|
|
15
14
|
// eslint-disable-next-line class-methods-use-this
|
|
16
15
|
renderHideButton() {
|
|
17
16
|
return nothing;
|
|
17
|
+
// import '@digital-realty/ix-button/ix-button.js';
|
|
18
18
|
// TO DO: this part will be completed with https://telxapp.atlassian.net/browse/IXUAT-8818
|
|
19
19
|
// return html`<ix-button appearance="text" has-icon @click=${this.onClosed}>
|
|
20
20
|
// <md-icon slot="icon">fullscreen_exit</md-icon>
|
package/dist/IxDrawer.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IxDrawer.js","sourceRoot":"","sources":["../src/IxDrawer.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,KAAK,CAAC;AAChD,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC7C,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9D,OAAO,
|
|
1
|
+
{"version":3,"file":"IxDrawer.js","sourceRoot":"","sources":["../src/IxDrawer.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,UAAU,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,KAAK,CAAC;AAChD,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC7C,OAAO,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAC9D,OAAO,4BAA4B,CAAC;AAEpC,MAAM,OAAO,QAAS,SAAQ,UAAU;IAAxC;;QAK+B,cAAS,GAAG,KAAK,CAAC;IAwCjD,CAAC;IA5CC,MAAM,KAAK,MAAM;QACf,OAAO,CAAC,cAAc,CAAC,CAAC;IAC1B,CAAC;IAMD,kDAAkD;IAClD,gBAAgB;QACd,OAAO,OAAO,CAAC;QAEf,mDAAmD;QACnD,0FAA0F;QAC1F,6EAA6E;QAC7E,mDAAmD;QACnD,SAAS;QACT,iBAAiB;IACnB,CAAC;IAED,MAAM;QACJ,IAAI,IAAI,CAAC,SAAS;YAChB,OAAO,IAAI,CAAA;;;;;kBAKC,IAAI,CAAC,gBAAgB,EAAE;;;;oCAIL,IAAI,CAAC,QAAQ;;;;;;;;;OAS1C,CAAC;QAEJ,OAAO,OAAO,CAAC;IACjB,CAAC;CACF;AAxC8B;IAA5B,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;2CAAmB;AAEjB;IAA7B,QAAQ,CAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC;0CAAe","sourcesContent":["import { LitElement, html, nothing } from 'lit';\nimport { property } from 'lit/decorators.js';\nimport { IxDrawerStyles } from './styles/ix-drawer-styles.js';\nimport '@material/web/icon/icon.js';\n\nexport class IxDrawer extends LitElement {\n static get styles() {\n return [IxDrawerStyles];\n }\n\n @property({ type: Boolean }) isVisible = false;\n\n @property({ type: Function }) onClosed: any;\n\n // eslint-disable-next-line class-methods-use-this\n renderHideButton() {\n return nothing;\n\n // import '@digital-realty/ix-button/ix-button.js';\n // TO DO: this part will be completed with https://telxapp.atlassian.net/browse/IXUAT-8818\n // return html`<ix-button appearance=\"text\" has-icon @click=${this.onClosed}>\n // <md-icon slot=\"icon\">fullscreen_exit</md-icon>\n // Hide\n // </ix-button>`;\n }\n\n render() {\n if (this.isVisible)\n return html`\n <div class=\"drawer-container\">\n <aside class=\"drawer\">\n <div class=\"drawer-header\">\n <div class=\"drawer-header__hide-btn\">\n ${this.renderHideButton()}\n </div>\n <div class=\"drawer-header__close-btn\">\n <div class=\"drawer-header__close-btn-hover-layer\">\n <md-icon @click=${this.onClosed}>Close</md-icon>\n </div>\n </div>\n </div>\n <div class=\"drawer-body\">\n <slot name=\"content\"></slot>\n </div>\n </aside>\n </div>\n `;\n\n return nothing;\n }\n}\n"]}
|
|
@@ -14,7 +14,7 @@ export const IxDrawerStyles = css `
|
|
|
14
14
|
}
|
|
15
15
|
|
|
16
16
|
.drawer {
|
|
17
|
-
width:
|
|
17
|
+
width: 90%;
|
|
18
18
|
height: 100%;
|
|
19
19
|
float: right;
|
|
20
20
|
padding: 32px 40px 40px;
|
|
@@ -22,7 +22,11 @@ export const IxDrawerStyles = css `
|
|
|
22
22
|
border-radius: 20px 0px 0px 20px;
|
|
23
23
|
box-sizing: border-box;
|
|
24
24
|
}
|
|
25
|
-
|
|
25
|
+
@media screen and (min-width: 768px) {
|
|
26
|
+
.drawer {
|
|
27
|
+
width: 45%;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
26
30
|
.drawer-header {
|
|
27
31
|
display: flex;
|
|
28
32
|
justify-content: space-between;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ix-drawer-styles.js","sourceRoot":"","sources":["../../src/styles/ix-drawer-styles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAE1B,MAAM,CAAC,MAAM,cAAc,GAAG,GAAG,CAAA
|
|
1
|
+
{"version":3,"file":"ix-drawer-styles.js","sourceRoot":"","sources":["../../src/styles/ix-drawer-styles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAE1B,MAAM,CAAC,MAAM,cAAc,GAAG,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAsDhC,CAAC","sourcesContent":["import { css } from 'lit';\n\nexport const IxDrawerStyles = css`\n .drawer-container {\n z-index: 1;\n display: block;\n position: absolute;\n width: 100%;\n height: 100%;\n top: 0;\n left: 0;\n background-color: rgba(0, 0, 0, 0.2);\n scroll-behavior: auto;\n overflow: auto;\n }\n\n .drawer {\n width: 90%;\n height: 100%;\n float: right;\n padding: 32px 40px 40px;\n background-color: white;\n border-radius: 20px 0px 0px 20px;\n box-sizing: border-box;\n }\n @media screen and (min-width: 768px) {\n .drawer {\n width: 45%;\n }\n }\n .drawer-header {\n display: flex;\n justify-content: space-between;\n align-items: center;\n }\n .drawer-header__hide-btn {\n flex: 0;\n }\n .drawer-header__close-btn {\n flex: 1;\n }\n .drawer-header__close-btn-hover-layer {\n width: 24px;\n height: 24px;\n border-radius: 9999px;\n float: right;\n }\n .drawer-header__close-btn-hover-layer:hover {\n transition: 0.15s;\n background-color: lightgrey;\n }\n\n .drawer-body {\n height: 100%;\n overflow: auto;\n }\n`;\n"]}
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"description": "Webcomponent ix-drawer following open-wc recommendations",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"author": "interxion",
|
|
6
|
-
"version": "1.0.
|
|
6
|
+
"version": "1.0.4",
|
|
7
7
|
"type": "module",
|
|
8
8
|
"main": "dist/index.js",
|
|
9
9
|
"module": "dist/index.js",
|
|
@@ -22,14 +22,12 @@
|
|
|
22
22
|
"prepublish": "tsc && npm run analyze -- --exclude dist",
|
|
23
23
|
"lint": "eslint --ext .ts,.html . --ignore-path .gitignore && prettier \"**/*.ts\" --check --ignore-path .gitignore",
|
|
24
24
|
"format": "eslint --ext .ts,.html . --fix --ignore-path .gitignore && prettier \"**/*.ts\" --write --ignore-path .gitignore",
|
|
25
|
-
"
|
|
25
|
+
"test2": "tsc && wtr --coverage",
|
|
26
26
|
"test:watch": "tsc && concurrently -k -r \"tsc --watch --preserveWatchOutput\" \"wtr --watch\"",
|
|
27
27
|
"storybook": "tsc && npm run analyze -- --exclude dist && concurrently -k -r \"tsc --watch --preserveWatchOutput\" \"wds -c .storybook/server.mjs\"",
|
|
28
28
|
"storybook:build": "tsc && npm run analyze -- --exclude dist && build-storybook"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@digital-realty/ix-button": "*",
|
|
32
|
-
"@digital-realty/theme": "*",
|
|
33
31
|
"@lit/react": "^1.0.2",
|
|
34
32
|
"@material/web": "^1.0.1",
|
|
35
33
|
"lit": "^2.0.2",
|
|
@@ -103,5 +101,5 @@
|
|
|
103
101
|
"README.md",
|
|
104
102
|
"LICENSE"
|
|
105
103
|
],
|
|
106
|
-
"gitHead": "
|
|
104
|
+
"gitHead": "15fe921385c2caa45181ac798db9a6d4fc9f92f0"
|
|
107
105
|
}
|