About window

This commit is contained in:
barsdeveloper
2025-01-25 22:03:46 +02:00
parent 0c6bda6fd4
commit 6167e97406
10 changed files with 92 additions and 6 deletions

View File

@@ -34,6 +34,15 @@ ueb-blueprint svg {
z-index: 1;
}
.ueb-viewport-about {
margin-top: -6px;
padding: 0 8px;
align-self: center;
font-size: 20px;
font-weight: bolder;
cursor: pointer;
}
@keyframes ueb-zoom-animation {
0% {
color: #7f7f7f;
@@ -145,6 +154,20 @@ ueb-selector > * {
overflow: hidden;
}
.ueb-info-dialog {
border: 10px solid #181818;
padding: 5px 30px;
background: #101010;
color: #f0f0f0;
}
.ueb-info-dialog a:link,
.ueb-info-dialog a:visited,
.ueb-info-dialog a:hover,
.ueb-info-dialog a:active {
outline: none;
color: #f0f0f0;
}
ueb-node.ueb-node-style-minimal {
box-shadow: none;
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

18
dist/ueblueprint.js vendored
View File

@@ -25,6 +25,7 @@ const t$1=globalThis,i$3=t$1.trustedTypes,s=i$3?i$3.createPolicy("lit-html",{cre
*/class r extends b{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0;}createRenderRoot(){const t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){const s=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=B(s,this.renderRoot,this.renderOptions);}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0);}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1);}render(){return T}}r._$litElement$=!0,r["finalized"]=!0,globalThis.litElementHydrateSupport?.({LitElement:r});const i$2=globalThis.litElementPolyfillSupport;i$2?.({LitElement:r});(globalThis.litElementVersions??=[]).push("4.1.1");
class Configuration {
static VERSION = "2.0.0"
static nodeColors = {
black: i$5`20, 20, 20`,
blue: i$5`84, 122, 156`,
@@ -11160,6 +11161,11 @@ class BlueprintTemplate extends ITemplate {
render() {
return x`
<div class="ueb-viewport-header">
<div class="ueb-viewport-about">
<a @click="${e => e.target.closest("ueb-blueprint").querySelector(".ueb-info-dialog").showModal()}">
</a>
</div>
<div class="ueb-viewport-zoom">
Zoom ${this.blueprint.zoom == 0 ? "1:1" : (this.blueprint.zoom > 0 ? "+" : "") + this.blueprint.zoom}
</div>
@@ -11175,6 +11181,18 @@ class BlueprintTemplate extends ITemplate {
</div>
</div>
</div>
<dialog class="ueb-info-dialog" @click="${e => e.target.closest(".ueb-info-dialog").close()}">
<h2>UEBlueprint</h2>
<p>A stand alone editor implementation of the UE's Blueprint visual language.</p>
<p>
Version: ${Configuration.VERSION}<br />
Author: barsdeveloper<br />
License: MIT<br />
<a target="_blank" href="https://github.com/barsdeveloper/ueblueprint">
https://github.com/barsdeveloper/ueblueprint
</a>
</p>
</dialog>
`
}

File diff suppressed because one or more lines are too long

View File

@@ -1,6 +1,7 @@
import { css } from "lit"
export default class Configuration {
static VERSION = "2.0.0"
static nodeColors = {
black: css`20, 20, 20`,
blue: css`84, 122, 156`,

View File

@@ -140,6 +140,11 @@ export default class BlueprintTemplate extends ITemplate {
render() {
return html`
<div class="ueb-viewport-header">
<div class="ueb-viewport-about">
<a @click="${e => e.target.closest("ueb-blueprint").querySelector(".ueb-info-dialog").showModal()}">
</a>
</div>
<div class="ueb-viewport-zoom">
Zoom ${this.blueprint.zoom == 0 ? "1:1" : (this.blueprint.zoom > 0 ? "+" : "") + this.blueprint.zoom}
</div>
@@ -155,6 +160,18 @@ export default class BlueprintTemplate extends ITemplate {
</div>
</div>
</div>
<dialog class="ueb-info-dialog" @click="${e => e.target.closest(".ueb-info-dialog").close()}">
<h2>UEBlueprint</h2>
<p>A stand alone editor implementation of the UE's Blueprint visual language.</p>
<p>
Version: ${Configuration.VERSION}<br />
Author: barsdeveloper<br />
License: MIT<br />
<a target="_blank" href="https://github.com/barsdeveloper/ueblueprint">
https://github.com/barsdeveloper/ueblueprint
</a>
</p>
</dialog>
`
}

View File

@@ -36,6 +36,15 @@ ueb-blueprint svg {
z-index: 1;
}
.ueb-viewport-about {
margin-top: -6px;
padding: 0 8px;
align-self: center;
font-size: 20px;
font-weight: bolder;
cursor: pointer;
}
@keyframes ueb-zoom-animation {
0% {
color: #7f7f7f;
@@ -257,3 +266,18 @@ ueb-selector>* {
text-overflow: ellipsis;
overflow: hidden;
}
.ueb-info-dialog {
border: 10px solid #181818;
padding: 5px 30px;
background: #101010;
color: #f0f0f0;
a:link,
a:visited,
a:hover,
a:active {
outline: none;
color: #f0f0f0;
}
}

View File

@@ -61,7 +61,8 @@ testNode({
await input.evaluate(() => navigator.clipboard.writeText(String.raw`"some \"word\" escaped"`))
await input.press("Control+V")
await input.blur()
expect(await pins[1].evaluate(p => p.entity.DefaultValue.serialize())).toEqual(String.raw`"\"some \\\"word\\\" escaped\""`)
expect(await pins[1].evaluate(p => p.entity.DefaultValue.serialize()))
.toEqual(String.raw`"\"some \\\"word\\\" escaped\""`)
await input.focus()
await input.evaluate(() => navigator.clipboard.writeText(String.raw`1'2'3`))
@@ -76,7 +77,9 @@ testNode({
expect(await pins[1].evaluate(p => p.entity.DefaultValue.serialize())).toEqual('"1`2`3"')
await input.focus()
await input.evaluate(() => navigator.clipboard.writeText(String.raw` alpha + 'beta'${"\n"}text: "gamma"${"\n"}multiline: ${"`\n"} "Some 'text' \"quoted\"";${"\n`"}`))
await input.evaluate(() => navigator.clipboard.writeText(
String.raw` alpha + 'beta'${"\n"}text: "gamma"${"\n"}multiline: ${"`\n"} "Some 'text' \"quoted\"";${"\n`"}`)
)
await input.press("Control+V")
await input.blur()
expect(await pins[1].evaluate(p => p.entity.DefaultValue.serialize())).toEqual(