proto-table-wc 0.0.400 → 0.0.402
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cjs/demo-table_2.cjs.entry.js +1 -1
- package/dist/cjs/{index-52ab0f4a.js → index-76fed79c.js} +7 -0
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/proto-table-wc.cjs.js +2 -2
- package/dist/collection/collection-manifest.json +2 -2
- package/dist/esm/demo-table_2.entry.js +1 -1
- package/dist/esm/{index-f60c9fab.js → index-dc847a9f.js} +7 -0
- package/dist/esm/loader.js +3 -3
- package/dist/esm/proto-table-wc.js +3 -3
- package/dist/proto-table-wc/{p-8b0ca37d.entry.js → p-234abb83.entry.js} +1 -1
- package/dist/proto-table-wc/proto-table-wc.esm.js +1 -1
- package/package.json +4 -4
- /package/dist/proto-table-wc/{p-6cf8a72f.js → p-9534e369.js} +0 -0
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
4
4
|
|
5
|
-
const index = require('./index-
|
5
|
+
const index = require('./index-76fed79c.js');
|
6
6
|
|
7
7
|
const demoTableCss = ".detailWrapper{font-weight:100;font-size:13px;display:flex;flex-direction:column;justify-items:start;padding:5px;padding-left:30px}";
|
8
8
|
|
@@ -63,6 +63,13 @@ const EMPTY_OBJ = {};
|
|
63
63
|
const SVG_NS = 'http://www.w3.org/2000/svg';
|
64
64
|
const HTML_NS = 'http://www.w3.org/1999/xhtml';
|
65
65
|
const isDef = (v) => v != null;
|
66
|
+
/**
|
67
|
+
* Check whether a value is a 'complex type', defined here as an object or a
|
68
|
+
* function.
|
69
|
+
*
|
70
|
+
* @param o the value to check
|
71
|
+
* @returns whether it's a complex type or not
|
72
|
+
*/
|
66
73
|
const isComplexType = (o) => {
|
67
74
|
// https://jsperf.com/typeof-fn-object/5
|
68
75
|
o = typeof o;
|
package/dist/cjs/loader.cjs.js
CHANGED
@@ -2,10 +2,10 @@
|
|
2
2
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
4
4
|
|
5
|
-
const index = require('./index-
|
5
|
+
const index = require('./index-76fed79c.js');
|
6
6
|
|
7
7
|
/*
|
8
|
-
Stencil Client Patch Esm v3.0.
|
8
|
+
Stencil Client Patch Esm v3.0.1 | MIT Licensed | https://stenciljs.com
|
9
9
|
*/
|
10
10
|
const patchEsm = () => {
|
11
11
|
return index.promiseResolve();
|
@@ -2,10 +2,10 @@
|
|
2
2
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
4
4
|
|
5
|
-
const index = require('./index-
|
5
|
+
const index = require('./index-76fed79c.js');
|
6
6
|
|
7
7
|
/*
|
8
|
-
Stencil Client Patch Browser v3.0.
|
8
|
+
Stencil Client Patch Browser v3.0.1 | MIT Licensed | https://stenciljs.com
|
9
9
|
*/
|
10
10
|
const patchBrowser = () => {
|
11
11
|
const importMeta = (typeof document === 'undefined' ? new (require('u' + 'rl').URL)('file:' + __filename).href : (document.currentScript && document.currentScript.src || new URL('proto-table-wc.cjs.js', document.baseURI).href));
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { r as registerInstance, h } from './index-
|
1
|
+
import { r as registerInstance, h } from './index-dc847a9f.js';
|
2
2
|
|
3
3
|
const demoTableCss = ".detailWrapper{font-weight:100;font-size:13px;display:flex;flex-direction:column;justify-items:start;padding:5px;padding-left:30px}";
|
4
4
|
|
@@ -41,6 +41,13 @@ const EMPTY_OBJ = {};
|
|
41
41
|
const SVG_NS = 'http://www.w3.org/2000/svg';
|
42
42
|
const HTML_NS = 'http://www.w3.org/1999/xhtml';
|
43
43
|
const isDef = (v) => v != null;
|
44
|
+
/**
|
45
|
+
* Check whether a value is a 'complex type', defined here as an object or a
|
46
|
+
* function.
|
47
|
+
*
|
48
|
+
* @param o the value to check
|
49
|
+
* @returns whether it's a complex type or not
|
50
|
+
*/
|
44
51
|
const isComplexType = (o) => {
|
45
52
|
// https://jsperf.com/typeof-fn-object/5
|
46
53
|
o = typeof o;
|
package/dist/esm/loader.js
CHANGED
@@ -1,8 +1,8 @@
|
|
1
|
-
import { p as promiseResolve, b as bootstrapLazy } from './index-
|
2
|
-
export { s as setNonce } from './index-
|
1
|
+
import { p as promiseResolve, b as bootstrapLazy } from './index-dc847a9f.js';
|
2
|
+
export { s as setNonce } from './index-dc847a9f.js';
|
3
3
|
|
4
4
|
/*
|
5
|
-
Stencil Client Patch Esm v3.0.
|
5
|
+
Stencil Client Patch Esm v3.0.1 | MIT Licensed | https://stenciljs.com
|
6
6
|
*/
|
7
7
|
const patchEsm = () => {
|
8
8
|
return promiseResolve();
|
@@ -1,8 +1,8 @@
|
|
1
|
-
import { p as promiseResolve, b as bootstrapLazy } from './index-
|
2
|
-
export { s as setNonce } from './index-
|
1
|
+
import { p as promiseResolve, b as bootstrapLazy } from './index-dc847a9f.js';
|
2
|
+
export { s as setNonce } from './index-dc847a9f.js';
|
3
3
|
|
4
4
|
/*
|
5
|
-
Stencil Client Patch Browser v3.0.
|
5
|
+
Stencil Client Patch Browser v3.0.1 | MIT Licensed | https://stenciljs.com
|
6
6
|
*/
|
7
7
|
const patchBrowser = () => {
|
8
8
|
const importMeta = import.meta.url;
|
@@ -1 +1 @@
|
|
1
|
-
import{r as t,h as e}from"./p-
|
1
|
+
import{r as t,h as e}from"./p-9534e369.js";const r=class{constructor(r){t(this,r),this.fields=[{label:"Date",prop:"date"},{label:"List Price",prop:"price"},{label:"% of Market",prop:"market"},{label:"ProfitTime Score",prop:"score"}],this.items=[],this.table=void 0,this.renderDetails=t=>{const{tags:r=[]}=t;return e("div",{class:"detailWrapper"},e("span",null,r.length," details..."),e("ul",null,r.map((t=>e("li",null,t)))))}}componentWillLoad(){this.items=[{date:"08/30/2020",price:"$24,000",market:"98%",score:"No Score",tags:["one","two","three"]},{date:"08/31/2020",price:"$24,000",market:"99%",score:"No Score",tags:["uno","duo"]},{date:"09/01/2020",price:"$27,000",market:"102%",score:"Platinum"},{date:"09/02/2020",price:"$27,423",market:"104%",score:"Platinum",tags:["dog","cat","fish","hamster"]},{date:"09/03/2020",price:"$27,521",market:"106%",score:"Platinum",tags:["4wd","sports"]},{date:"09/04/2020",price:"$27,687",market:"107%",score:"Platinum",tags:["leather","chrome"]}]}componentDidLoad(){const{table:t,items:e,fields:r}=this;t.data=e,t.fields=r,t.details=this.renderDetails}render(){return e("proto-table",{ref:t=>this.table=t})}};r.style=".detailWrapper{font-weight:100;font-size:13px;display:flex;flex-direction:column;justify-items:start;padding:5px;padding-left:30px}";const s={down:"M12 15.4L6.6 10 8 8.6l4 4 4-4 1.4 1.4z",up:"M16 15.4l-4-4-4 4L6.6 14 12 8.6l5.4 5.4z",left:"M14 17.4L8.6 12 14 6.6 15.4 8l-4 4 4 4z",right:"M10 17.4L8.6 16l4-4-4-4L10 6.6l5.4 5.4z",more:"M12 14a2 2 0 100-4 2 2 0 000 4zm-6 0a2 2 0 100-4 2 2 0 000 4zm12 0a2 2 0 100-4 2 2 0 000 4z","arrow-up":"M5.3 10.7l1.4 1.4L11 7.8V20h2V7.8l4.3 4.3 1.4-1.4L12 4z","arrow-down":"M18.7 13.3l-1.4-1.4-4.3 4.3V4h-2v12.2l-4.3-4.3-1.4 1.4L12 20z"},i={right:"show",down:"hide","arrow-up":"sort","arrow-down":"sort"},l=class{constructor(r){t(this,r),this.protoIcon=(t,r,l=24)=>{const o=s[t];return e("svg",{width:l,height:l,viewBox:"0 0 24 24",role:"img","aria-labelledby":"title"},e("title",null,(t=>i[t])(t)),e("g",{fill:r},e("path",{d:o})),e("path",{d:"M0 0h24v24H0z",fill:"none"}))},this.handleCellClick=(t,e)=>()=>{0===t&&(this.expanded=this.expanded===e?void 0:e)},this.handleSortClick=t=>()=>{this.sort===t?2===this.clicks?(this.clicks=0,this.sort=void 0):this.clicks=this.clicks+1:(this.sort=t,this.clicks=1)},this.iconFor=t=>this.sort===t&&2===this.clicks?"arrow-up":"arrow-down",this.header=()=>{const{fields:t,iconFor:r,protoIcon:s}=this;return e("div",{class:"header"},t.map((({label:t},i)=>{const l=i===this.sort?"headerCell sort":"headerCell",o=r(i);return e("div",{class:l,onClick:this.handleSortClick(i)},s(o),e("span",null,t))})))},this.row=(t,r)=>{const{fields:s,protoIcon:i}=this;return e("div",{class:"rowContainer"},e("div",{class:this.expanded===r?"row expanded":"row"},s.map((({prop:s},l)=>e("div",{class:l===this.sort?"cell sort":"cell",onClick:this.handleCellClick(l,r)},i(0===l&&this.details?this.expanded===r?"down":"right":"pad"),t[s])))),this.details&&this.expanded===r&&this.details(t))},this.data=[],this.details=void 0,this.fields=[],this.expanded=void 0,this.sort=void 0,this.clicks=0}render(){const t=this.data||[];return e("div",{class:"table"},this.header(),t.map(((t,e)=>this.row(t,e))))}};l.style=".table{font-weight:400;font-size:13px;display:flex;flex-direction:column;width:100%;border:1px solid var(--clrs-navy);border-radius:2px}.table svg{fill:var(--clrs-navy)}.header{display:flex}.headerCell{flex-basis:100%;display:flex;align-items:center;justify-items:start;border-right:1px solid var(--clrs-navy);border-bottom:1px solid var(--clrs-navy);padding:5px;cursor:pointer}.headerCell svg g{display:none}.headerCell.sort svg g{display:inline}.headerCell:hover svg g{display:inline}.headerCell:hover{background-color:var(--clrs-silver)}.headerCell:last-child{border-right:none}.cell{flex-basis:100%;display:flex;align-items:center;justify-items:start;padding:5px}.cell:first-child svg{cursor:pointer}.sort{background-color:var(--cx-column-sort)}.row{display:flex;justify-items:stretch;width:100%}.row.expanded{background-color:var(--cx-row-expanded)}.row.expanded svg{fill:var(--clrs-red)}.row:hover{background-color:var(--cx-row-hover)}";export{r as demo_table,l as proto_table}
|
@@ -1 +1 @@
|
|
1
|
-
import{p as
|
1
|
+
import{p as e,b as t}from"./p-9534e369.js";export{s as setNonce}from"./p-9534e369.js";(()=>{const s=import.meta.url,t={};return""!==s&&(t.resourcesUrl=new URL(".",s).href),e(t)})().then((e=>t([["p-234abb83",[[1,"demo-table"],[0,"proto-table",{data:[16],details:[8],fields:[16],expanded:[32],sort:[32],clicks:[32]}]]]],e)));
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "proto-table-wc",
|
3
|
-
"version": "0.0.
|
3
|
+
"version": "0.0.402",
|
4
4
|
"description": "Stencil Component Starter",
|
5
5
|
"main": "dist/index.cjs.js",
|
6
6
|
"module": "dist/index.js",
|
@@ -25,11 +25,11 @@
|
|
25
25
|
"format": "prettier --write src"
|
26
26
|
},
|
27
27
|
"dependencies": {
|
28
|
-
"@stencil/core": "3.0.
|
28
|
+
"@stencil/core": "3.0.1"
|
29
29
|
},
|
30
30
|
"devDependencies": {
|
31
|
-
"cspell": "6.
|
32
|
-
"eslint": "8.
|
31
|
+
"cspell": "6.27.0",
|
32
|
+
"eslint": "8.35.0",
|
33
33
|
"prettier": "2.8.4",
|
34
34
|
"tslint": "6.1.3",
|
35
35
|
"typescript": "4.9.5"
|
File without changes
|