mirror of
https://github.com/penpot/penpot.git
synced 2025-05-10 22:16:38 +02:00
🐛 Remove data-testid usage from shape
This commit is contained in:
parent
dd220e228e
commit
35bcb082a0
2 changed files with 1 additions and 10 deletions
|
@ -168,7 +168,7 @@ export class WorkspacePage extends BaseWebSocketPage {
|
||||||
async moveSelectionToShape(name) {
|
async moveSelectionToShape(name) {
|
||||||
await this.page.locator("rect.viewport-selrect").hover();
|
await this.page.locator("rect.viewport-selrect").hover();
|
||||||
await this.page.mouse.down();
|
await this.page.mouse.down();
|
||||||
await this.viewport.getByTestId(name).first().hover({ force: true });
|
await this.viewport.getByText(name).first().hover({ force: true });
|
||||||
await this.page.mouse.up();
|
await this.page.mouse.up();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -13,7 +13,6 @@
|
||||||
[app.main.ui.context :as muc]
|
[app.main.ui.context :as muc]
|
||||||
[app.main.ui.hooks :as h]
|
[app.main.ui.hooks :as h]
|
||||||
[app.main.ui.shapes.attrs :as attrs]
|
[app.main.ui.shapes.attrs :as attrs]
|
||||||
[app.main.ui.shapes.embed :as embed]
|
|
||||||
[app.main.ui.shapes.export :as ed]
|
[app.main.ui.shapes.export :as ed]
|
||||||
[app.main.ui.shapes.fills :as fills]
|
[app.main.ui.shapes.fills :as fills]
|
||||||
[app.main.ui.shapes.filters :as filters]
|
[app.main.ui.shapes.filters :as filters]
|
||||||
|
@ -79,7 +78,6 @@
|
||||||
(obj/set! "mixBlendMode" (d/name blend-mode))))
|
(obj/set! "mixBlendMode" (d/name blend-mode))))
|
||||||
|
|
||||||
include-metadata? (mf/use-ctx ed/include-metadata-ctx)
|
include-metadata? (mf/use-ctx ed/include-metadata-ctx)
|
||||||
embed? (mf/use-ctx embed/context)
|
|
||||||
|
|
||||||
shape-without-blur (dissoc shape :blur)
|
shape-without-blur (dissoc shape :blur)
|
||||||
shape-without-shadows (assoc shape :shadow [])
|
shape-without-shadows (assoc shape :shadow [])
|
||||||
|
@ -114,13 +112,6 @@
|
||||||
(-> (attrs/add-fill-props! shape render-id)
|
(-> (attrs/add-fill-props! shape render-id)
|
||||||
(attrs/add-border-props! shape))
|
(attrs/add-border-props! shape))
|
||||||
|
|
||||||
;; FIXME: this can set the data-testid attribute with
|
|
||||||
;; invalid values (unescaped) what can cause unexpected
|
|
||||||
;; problems; we don't set this attribute when embed is
|
|
||||||
;; enabled for fix the output on the svg exportation process
|
|
||||||
(not embed?)
|
|
||||||
(obj/set! "data-testid" (:name shape))
|
|
||||||
|
|
||||||
(some? filter-str)
|
(some? filter-str)
|
||||||
(obj/set! "filter" filter-str))
|
(obj/set! "filter" filter-str))
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue