Skip to content

Commit

Permalink
more deps cleaned up from testing
Browse files Browse the repository at this point in the history
  • Loading branch information
btopro committed Oct 21, 2024
1 parent cce5623 commit 86e5236
Show file tree
Hide file tree
Showing 9 changed files with 93 additions and 40 deletions.
2 changes: 1 addition & 1 deletion elements/code-editor/lib/code-pen-button.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class CodePenButton extends LitElement {
}
render() {
return html`
<form action="${this.endPoint}" method="POST" target="_blank">
<form action="${this.endPoint}" method="post" target="_blank">
<input type="hidden" name="data" value="${this.dataString}" />
<input
type="image"
Expand Down
16 changes: 14 additions & 2 deletions elements/d-d-d/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,22 @@
},
"license": "Apache-2.0",
"dependencies": {
"@haxtheweb/hax-iconset": "^9.0.7",
"lit": "^3.2.0",
"@haxtheweb/simple-colors": "^9.0.7",
"@haxtheweb/hax-iconset": "^9.0.7",
"@haxtheweb/simple-icon": "^9.0.7",
"lit": "^3.2.0"
"@haxtheweb/page-section": "^9.0.7",
"@haxtheweb/simple-cta": "^9.0.7",
"@haxtheweb/video-player": "^9.0.7",
"@haxtheweb/figure-label": "^9.0.7",
"@haxtheweb/stop-note": "^9.0.7",
"@haxtheweb/course-design": "^9.0.7",
"@haxtheweb/self-check": "^9.0.7",
"@haxtheweb/media-image": "^9.0.7",
"@haxtheweb/accent-card": "^9.0.7",
"@haxtheweb/simple-modal": "^9.0.7",
"@haxtheweb/haxcms-elements": "^9.0.7",
"mobx": "^6.13.5"
},
"devDependencies": {
"@haxtheweb/deduping-fix": "^9.0.7",
Expand Down
1 change: 1 addition & 0 deletions elements/md-block/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
},
"license": "Apache-2.0",
"dependencies": {
"@haxtheweb/d-d-d": "^9.0.7",
"@polymer/marked-element": "3.0.1",
"lit": "^3.2.0",
"marked": "5.1.0"
Expand Down
1 change: 1 addition & 0 deletions elements/simple-toast/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
"license": "Apache-2.0",
"dependencies": {
"@haxtheweb/simple-colors": "^9.0.7",
"@haxtheweb/d-d-d": "^9.0.7",
"lit": "^3.2.0"
},
"devDependencies": {
Expand Down
8 changes: 7 additions & 1 deletion elements/sorting-question/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,13 @@
},
"license": "Apache-2.0",
"dependencies": {
"lit": "^3.2.0"
"lit": "^3.2.0",
"@haxtheweb/multiple-choice": "^9.0.7",
"@haxtheweb/simple-toolbar": "^9.0.7",
"@haxtheweb/simple-toast": "^9.0.7",
"@haxtheweb/grid-plate": "^9.0.7",
"@haxtheweb/d-d-d": "^9.0.7",
"@haxtheweb/simple-icon": "^9.0.7"
},
"devDependencies": {
"@haxtheweb/deduping-fix": "^9.0.7",
Expand Down
3 changes: 2 additions & 1 deletion elements/tagging-question/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@
},
"license": "Apache-2.0",
"dependencies": {
"lit": "^3.2.0"
"lit": "^3.2.0",
"@haxtheweb/multiple-choice": "^9.0.7"
},
"devDependencies": {
"@haxtheweb/deduping-fix": "^9.0.7",
Expand Down
2 changes: 1 addition & 1 deletion elements/web-container/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ <h1>web-container</h1>
let wcm = await globalThis.WebContainerManager.requestAvailability();
let wcdp = globalThis.document.createElement('web-container-doc-player');
let ary = globalThis.filteredWcRegistry[select.value].split('/');
wcdp.project = globalThis.filteredWcRegistry[select.value] = `${ary.shift()}/${ary.shift()}`;
wcdp.project = `${ary.shift()}/${ary.shift()}`;
wcdp.element = select.value;
wcdp.importpath = globalThis.filteredWcRegistry[select.value];
let container = globalThis.document.querySelector('#container');
Expand Down
32 changes: 31 additions & 1 deletion elements/web-container/lib/web-container-doc-player.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,17 @@ export class WebContainerDocPlayer extends DDDSuper(LitElement) {
this.importpath = null;
this.version = "latest";
this.rebuilding = false;
// listen for the frame sending back it's height
globalThis.addEventListener(
'message',
(e) => {
// message that was passed from iframe page
let message = JSON.parse(e.data);
if (message.subject === "frameResize" && message.height) {
this.shadowRoot.querySelector('web-container').style.setProperty('--web-container-iframe-height', parseInt(message.height) + 40 + "px");
}
}
);
}

updated(changedProperties) {
Expand Down Expand Up @@ -57,6 +68,13 @@ export class WebContainerDocPlayer extends DDDSuper(LitElement) {
<div id="codesample"></div>
<div id="demo"></div>
</body>
<script>
window.process = window.process || {
env: {
NODE_ENV: "production"
}
};
</script>
<script type="module" async defer>
import "${this.importpath ? this.importpath : this.project}";
import "@haxtheweb/code-sample/code-sample.js";
Expand All @@ -75,7 +93,7 @@ export class WebContainerDocPlayer extends DDDSuper(LitElement) {
return false;
});
}
if (schema.demoSchema && schema.demoSchema[0]) {
if (schema && schema.demoSchema && schema.demoSchema[0]) {
el = haxElementToNode(schema.demoSchema[0]);
}
}
Expand All @@ -87,6 +105,18 @@ export class WebContainerDocPlayer extends DDDSuper(LitElement) {
let sampleWrapper = globalThis.document.querySelector('#codesample');
sampleWrapper.innerHTML = '';
sampleWrapper.appendChild(sample);
const bodyObserver = new ResizeObserver(entries => {
for (const entry of entries) {
if (entry.target === globalThis.document.body) {
const newHeight = entry.contentRect.height;
parent.postMessage(
'{"subject":"frameResize", "height":"' + entry.contentRect.height + '" }',
"*",
);
}
}
});
bodyObserver.observe(globalThis.document.body);
}
// generate example dynamically so we can use HAXProps if it exists
getExample();
Expand Down
68 changes: 35 additions & 33 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -52,78 +52,77 @@
"ubiquity-push": "bash scripts/ubiquity-push.sh",
"terser": "gulp terser --gulpfile=gulpfile.mjs",
"wc-autoloader": "gulp wc-autoloader --gulpfile=gulpfile.mjs",
"version-match": "gulp version-match --gulpfile=gulpfile.mjs"
"version-match": "gulp version-match --gulpfile=gulpfile.mjs",
"depcheck": "depcheck"
},
"peerDependencies": {
"@web/test-runner": "0.18.0",
"@web/test-runner-commands": "0.9.0",
"@web/test-runner-playwright": "0.11.0"
},
"dependencies": {
"patch-package": "8.0.0",
"validate-element-name": "3.0.0",
"@babel/core": "^7.9.0",
"yargs": "16.2.0",
"@emotion/core": "0.13.1",
"@emotion/styled": "0.10.6",
"@haxtheweb/course-design": "^9.0.2",
"@haxtheweb/lrn-math": "^9.0.2",
"@haxtheweb/media-image": "^9.0.2",
"@haxtheweb/video-player": "^9.0.2",
"@lit-labs/ssr": "^3.2.2",
"@lit-labs/virtualizer": "^2.0.14",
"@open-wc/building-utils": "2.18.4",
"@open-wc/demoing-storybook": "2.4.7",
"@open-wc/storybook": "0.2.8",
"@open-wc/storybook-prebuilt": "1.2.0",
"@open-wc/testing": "4.0.0",
"@open-wc/webpack-import-meta-loader": "0.4.7",
"@open-wc/storybook-prebuilt": "1.2.0",
"@rollup/plugin-commonjs": "21.0.1",
"html-element": "2.3.1",
"@webcomponents/webcomponentsjs": "^2.8.0",
"fetch-ie8": "1.5.0",
"lunr": "2.3.9",
"concurrently": "8.2.2",
"promise-polyfill": "8.2.1",
"depcheck": "^1.4.7",
"fetch-ie8": "1.5.0",
"html-element": "2.3.1",
"jsdom": "24.0.0",
"url": "0.11.0",
"turndown": "7.1.1",
"sharp": "0.33.2",
"markdown-it": "14.0.0",
"@lit-labs/virtualizer": "^2.0.14",
"lit-html": "^3.2.0",
"@lit-labs/ssr": "^3.2.2",
"lit": "^3.2.0",
"lit-html": "^3.2.0",
"lunr": "2.3.9",
"markdown-it": "14.0.0",
"node-html-parser": "^6.1.13",
"@haxtheweb/course-design": "^9.0.2",
"@haxtheweb/video-player": "^9.0.2",
"@haxtheweb/lrn-math": "^9.0.2",
"@haxtheweb/media-image": "^9.0.2"
"patch-package": "8.0.0",
"promise-polyfill": "8.2.1",
"sharp": "0.33.2",
"turndown": "7.1.1",
"url": "0.11.0",
"validate-element-name": "3.0.0",
"yargs": "16.2.0"
},
"devDependencies": {
"@haxtheweb/create": "^9.0.7",
"@babel/plugin-proposal-class-properties": "7.18.6",
"@babel/plugin-proposal-logical-assignment-operators": "7.20.7",
"@babel/plugin-proposal-nullish-coalescing-operator": "7.18.6",
"@babel/plugin-transform-optional-catch-binding": "7.23.4",
"@babel/plugin-proposal-optional-chaining": "7.21.0",
"@babel/plugin-transform-optional-catch-binding": "7.23.4",
"@babel/preset-env": "^7.16.4",
"@custom-elements-manifest/analyzer": "^0.9.0",
"commit-and-tag-version": "^12.4.1",
"@haxtheweb/create": "^9.0.7",
"@open-wc/building-rollup": "^2.0.1",
"@rollup/plugin-babel": "^6.0.3",
"@rollup/plugin-node-resolve": "^15.3.0",
"@web/dev-server": "0.4.6",
"@web/rollup-plugin-import-meta-assets": "^1.0.7",
"babel-plugin-template-html-minifier": "^4.1.0",
"deepmerge": "^4.2.2",
"rimraf": "^3.0.2",
"rollup-plugin-workbox": "^6.2.0",
"@web/rollup-plugin-html": "^2.0.1",
"@rollup/plugin-babel": "^6.0.3",
"web-animations-js": "2.3.2",
"@web/rollup-plugin-import-meta-assets": "^1.0.7",
"babel-loader": "8.2.3",
"babel-plugin-external-helpers": "6.22.0",
"babel-plugin-template-html-minifier": "^4.1.0",
"babel-plugin-transform-custom-element-classes": "0.1.0",
"babel-plugin-transform-dynamic-imports-to-static-imports": "1.0.0",
"babel-plugin-transform-es2015-modules-umd": "6.24.1",
"babel-preset-env": "1.7.0",
"chalk": "5.3.0",
"commit-and-tag-version": "^12.4.1",
"core-js": "3.21.1",
"decomment": "0.9.5",
"deepmerge": "^4.2.2",
"del": "6.0.0",
"dialog-polyfill": "0.5.6",
"file-loader": "6.2.0",
Expand Down Expand Up @@ -153,33 +152,36 @@
"lodash.clonedeep": "4.5.0",
"lorem-ipsum": "^2.0.3",
"npm-run-all": "^4.1.5",
"polymer-cli": "^1.9.11",
"polymer-build": "3.1.4",
"polymer-cli": "^1.9.11",
"polymer-webpack-loader": "2.0.3",
"prettier": "3.2.5",
"raw-loader": "4.0.2",
"react": "*",
"react-dom": "*",
"regenerator-runtime": "^0.13.5",
"requirejs": "2.3.7",
"rimraf": "^3.0.2",
"rollup": "2.78.0",
"rollup-plugin-auto-external": "^2.0.0",
"rollup-plugin-babel": "4.4.0",
"rollup-plugin-copy": "3.4.0",
"rollup-plugin-delete": "2.0.0",
"rollup-plugin-rewrite-imports": "2.0.0",
"rollup-plugin-terser": "7.0.2",
"rollup-plugin-workbox": "^6.2.0",
"strip-css-comments": "3.0.0",
"stylelint": "15.10.1",
"symlink-dir": "5.0.1",
"trim": "1.0.1",
"wct-browser-legacy": "1.0.2",
"web-animations-js": "2.3.2",
"web-component-analyzer": "1.1.7",
"web-component-tester": "6.9.2",
"webpack": "5.87.0",
"webpack-node-externals": "3.0.0",
"whatwg-fetch": "3.6.2",
"yo": "4.3.0",
"rollup-plugin-copy": "3.4.0"
"yo": "4.3.0"
},
"resolutions": {
"@mdjs/mdjs-preview": "0.5.9",
Expand Down

0 comments on commit 86e5236

Please sign in to comment.