![](/img/trans.png)
[英]Webpage using polymer library suddenly broken
在我的工作場所,一些 web 頁面幾天前突然開始出現故障(許多元素不再顯示在頁面中。)。 我在 firefox 使用開發人員工具 (F12) 檢查了這個問題,發現兩個 polymer 庫(即 1.7.0.2 版本中的 polymer-micro.html 和 paper-ripple-behavio ...
[英]Webpage using polymer library suddenly broken
在我的工作場所,一些 web 頁面幾天前突然開始出現故障(許多元素不再顯示在頁面中。)。 我在 firefox 使用開發人員工具 (F12) 檢查了這個問題,發現兩個 polymer 庫(即 1.7.0.2 版本中的 polymer-micro.html 和 paper-ripple-behavio ...
[英]Lit web component not updating Polymer element attribute
我一直在使用 Lit 庫引用 Home Assistant 項目對 Polymer 應用程序布局元素的使用。 我遇到的問題是我無法在自定義組件中獲取公共屬性來更新嵌套 Polymer 元素上的屬性。 這是我目前的代碼: import { LitElement, html, css, Propert ...
[英]Get Element out of Shadow DOM or use styles of main site
我正在一個使用 Polymer 的項目中工作(仍在 1.7 上,我們將使用不同的技術重新啟動而不是升級......)我應該檢查使其與 DynamicYield 一起工作的可能性,即一個個性化平台, 通過ShadowDOM 將個性化項目或推薦的 HTML 注入到一個人的頁面中。 shadowDOM ...
[英]how to trigger or click this button which uses aria-expanded to display a modal via console
所以我嘗試使用 document.querySelector('.d2l-contextmenu-ph').attr("aria-expanded","true"); 基本上點擊按鈕“hh”按鈕。 它對我不起作用,所以有人可以向我解釋如何單擊此按鈕,該按鈕將顯示 aria-expanded 屬性,該 ...
[英]Javascript function inside polymer is not a function error
我在 polymer 中定義了 javascript function: myTest(arg) {<do stuff here>} 在這個 function 中,根據某些條件,我想將onclick模板中定義的按鈕的 onclick 更改為其他一些 function。為此,我正在執行do ...
[英]AudioWorkletProcessor and Polymer 3.4.1 and 'window' not defined
嘗試使用 lit element/Polymer Web 組件和 Audioworklet/AudioWorklet 處理器時,出現此錯誤: 在我的代碼中的這一行: boot-c9e09360.js 是一個 polymer 文件,其中包含: @license 版權所有 (c) 2017 Poly ...
[英]Failed to resolve module of Polymer 3 in Electron v.17 application
我從 fluidnext 獲得了electron-quick-start和electron-polymer ,用於我的 Polymer 3 應用。 當我嘗試將我的 webcomponents 導入項目時,出現此錯誤: Uncaught TypeError: Failed to resolve mod ...
[英]JS method not defined
我想在 polymer 模板中使用 java 腳本方法。 我正在使用帶有 Polymer 元素的 Vaadin。 在我的項目中,我有一個可以是不同類型的對象的 Vaadin-Grid。 我想用不同的模板渲染這些類型。 可以使用 dom-if 模板解決此問題,如ollitietavainen在此答案中 ...
[英]RDkit fingerprint
我有 100 種聚合物,我想通過指紋比較它們的溶解度。 通過使用 rdkit,我得到了每個 polymer 的位列表,例如 [39、80、152、233、234、265、310、314、321、356、360、406、547、650、662、726、730、801 , 819, 849, 935]' ...
[英]Leaftlet: Adding feature overlay to control, dynamically
我需要將FeatureGroup添加到覆蓋列表中。 在實例化 Leaflet map 時,我確實添加了一些覆蓋,但我現在需要動態地 append 一個FeatureGroup ,即。 基於一些運行時條件。 有人可以幫忙附加 leaflet 控制層嗎? 我根本無法弄清楚這是否可能。 我可以將新層添加到 ...
[英]Detect click outside of the current web component
我有一個 web 組件(聚合物 3),它嵌入在其他組件中,並且想要“感知”它外部的點擊。 例如,在 React 中,我會在組件內部做這樣的事情: 上面我們只是簡單地添加了一個點擊事件,然后通過引用檢查該事件是否針對當前組件。 作為它的“反應語法”,我需要類似的東西,但對於 web 組件。 我需要參考 ...
[英]How to edit #shadow-root (user-agent) value in selenium with Python
我的工作環境是 Python、Chrome、Selenium 我想編輯 shadow-root (user-agent) 的值 如果我使用 js 的.getAttribute() ,輸入的 id "mytel" 可以附加值 1,但它不附加 shadow-root。 我想改變<div&g ...
[英]Stripe Elements cannot be mounted in a ShadowRoot. Please mount in the Light DOM
我一直在為我的發光元素項目使用 Stripe。 安裝卡元素根本不起作用。 這是我正在使用的代碼示例 每次我運行它時,我都會收到以下錯誤 Uncaught (in promise) IntegrationError: Elements cannot bemounted in a ShadowRoot. ...
[英]How to handle and pass events to the lit component from defining component
我正在嘗試使用 lit Element 設計 Web 組件,我需要有關事件的幫助。 正如我們從附加的代碼片段中看到的,我們可以在 html 模板中使用@change="${this.handleEvent}"並處理 lit Element 組件內的函數handleEvent(e){} 。 通過這種方 ...
[英]Vaadin Flow - how to add a custom icon set?
我正在使用 vaadin flow v21。 我喜歡創建一個使用自己的 svg 圖標集的自定義組件。 我嘗試基於 vaadin-icon 創建集合,但 svg 定義不會被復制到影子根中。 我做了以下 創建了一個從com.vaadin.flow.component.icon.Icon派生的Cus ...
[英]Advanced search in Javascript
我嘗試在項目中實現搜索欄。 當輸入不匹配時,它應該只搜索條目並隱藏行。 這就是我所做的並且正在起作用。 _searchCalls() { let rows = document.querySelector('call-journal').shadowRoot.querySelecto ...
[英]Version conflict - Uncaught DOMException, the name "mwc-icon" has already been used with this registry. Custom Component
我正在嘗試使用 Material Custom Component 並使用其他一些組件。 但是我有版本沖突Uncaught DOMException 。 未捕獲的 DOMException:無法在“CustomElementRegistry”上執行“define”:名稱“mwc-icon”已用於此注 ...
[英]Polymer/Lit-Element - Braintree gateway integration - Web Component problem
我正在嘗試將 Braintree 支付網關集成到使用 Polymer 作為其前端的 Vaadin 14。 基本上我們有一個自定義的 Vaadin 前端視圖來加載腳本https://js.braintreegateway.com/web/dropin/1.9.4/js/dropin.min.js : ...
[英]"Module parse failed: Unexpected character '@'" when using lit component with NextJS
我嘗試在我的 NextJS 項目中導入一個發光組件。 這是我的組件:import {html, css, LitElement} from 'lit'; import {customElement} from 'lit/decorators.js'; @customElement('my-ele ...
[英]update member of LitElement for the refreshing of the rendering?
我的擴展 LitElement class 具有變量成員,其值可以隨時更改。 渲染取決於其中的幾個。 我想知道,應該覆蓋哪個 update() 成員 function 以便在每次更新對 varialbe 成員的任何修改時刷新渲染更新。 ...