Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Augmentile
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Auglement
Augmentile
Commits
7300ee2b
Commit
7300ee2b
authored
4 years ago
by
Benedict Suska
Browse files
Options
Downloads
Patches
Plain Diff
Add login layout
parent
52c4e3a4
No related branches found
Branches containing commit
No related tags found
1 merge request
!6
Resolve "Login scene for browser backend"
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/artwork/loginbutton.svg
+78
-0
78 additions, 0 deletions
src/artwork/loginbutton.svg
src/frontend/scenes/login.js
+24
-3
24 additions, 3 deletions
src/frontend/scenes/login.js
with
102 additions
and
3 deletions
src/artwork/loginbutton.svg
0 → 100644
+
78
−
0
View file @
7300ee2b
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
xmlns:dc=
"http://purl.org/dc/elements/1.1/"
xmlns:cc=
"http://creativecommons.org/ns#"
xmlns:rdf=
"http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg=
"http://www.w3.org/2000/svg"
xmlns=
"http://www.w3.org/2000/svg"
xmlns:sodipodi=
"http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape=
"http://www.inkscape.org/namespaces/inkscape"
width=
"210mm"
height=
"297mm"
viewBox=
"0 0 210 297"
version=
"1.1"
id=
"svg8"
inkscape:export-filename=
"/home/benedict/Rastergrafik.png"
inkscape:export-xdpi=
"96"
inkscape:export-ydpi=
"96"
inkscape:version=
"1.0.2 (e86c870879, 2021-01-15)"
sodipodi:docname=
"loginbutton.svg"
>
<defs
id=
"defs2"
/>
<sodipodi:namedview
id=
"base"
pagecolor=
"#ffffff"
bordercolor=
"#666666"
borderopacity=
"1.0"
inkscape:pageopacity=
"0.0"
inkscape:pageshadow=
"2"
inkscape:zoom=
"0.35"
inkscape:cx=
"-708.53966"
inkscape:cy=
"232.98338"
inkscape:document-units=
"mm"
inkscape:current-layer=
"layer1"
inkscape:document-rotation=
"0"
showgrid=
"false"
inkscape:window-width=
"1920"
inkscape:window-height=
"1014"
inkscape:window-x=
"0"
inkscape:window-y=
"150"
inkscape:window-maximized=
"1"
/>
<metadata
id=
"metadata5"
>
<rdf:RDF>
<cc:Work
rdf:about=
""
>
<dc:format>
image/svg+xml
</dc:format>
<dc:type
rdf:resource=
"http://purl.org/dc/dcmitype/StillImage"
/>
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label=
"Ebene 1"
inkscape:groupmode=
"layer"
id=
"layer1"
>
<rect
style=
"fill:#f9f9f9;stroke-width:0.264583"
id=
"rect20"
width=
"49.148903"
height=
"19.463789"
x=
"69.17868"
y=
"65.184608"
/>
<text
xml:space=
"preserve"
style=
"font-style:normal;font-weight:normal;font-size:10.5833px;line-height:1.25;font-family:sans-serif;letter-spacing:0px;word-spacing:0px;fill:#000000;fill-opacity:1;stroke:none;stroke-width:0.264583"
x=
"85.404808"
y=
"78.534752"
id=
"text24"
inkscape:export-xdpi=
"96"
inkscape:export-ydpi=
"96"
><tspan
sodipodi:role=
"line"
id=
"tspan22"
x=
"85.404808"
y=
"78.534752"
style=
"stroke-width:0.264583"
>
Login
</tspan></text>
</g>
</svg>
This diff is collapsed.
Click to expand it.
src/frontend/scenes/login.js
+
24
−
3
View file @
7300ee2b
...
...
@@ -15,22 +15,43 @@
import
BaseScene
from
'
./base
'
;
import
logo
from
'
../../artwork/augmentile.svg
'
;
import
loginbutton
from
'
../../artwork/loginbutton.svg
'
;
class
LoginScene
extends
BaseScene
{
preload
()
{
this
.
load
.
image
(
'
logo
'
,
logo
);
this
.
load
.
image
(
'
login
'
,
loginbutton
);
}
create
()
{
//this.add.image(this.cameras.main.centerX, this.cameras.main.centerY, 'logo');
let
width
=
this
.
cameras
.
main
.
displayWidth
;
let
height
=
this
.
cameras
.
main
.
displayHeight
;
let
margin
=
20
;
const
textUserName
=
this
.
add
.
text
(
400
,
300
,
'
Username
'
,
{
fixedWidth
:
150
,
fixedHeight
:
36
});
const
textUserName
=
this
.
add
.
text
(
width
/
2
,
height
/
2
,
'
Username
'
,
{
fixedWidth
:
150
,
fixedHeight
:
36
});
textUserName
.
setOrigin
(
0.5
,
0.5
);
textUserName
.
setInteractive
().
on
(
'
pointerdown
'
,
function
()
{
console
.
log
(
this
);
this
.
scene
.
rexUI
.
edit
(
textUserName
);
});
}
const
textPassword
=
this
.
add
.
text
(
width
/
2
,
height
/
2
+
20
,
'
Password
'
,
{
fixedWidth
:
150
,
fixedHeight
:
36
});
textPassword
.
setOrigin
(
0.5
,
0.5
);
textPassword
.
setInteractive
().
on
(
'
pointerdown
'
,
function
()
{
console
.
log
(
this
);
this
.
scene
.
rexUI
.
edit
(
textPassword
);
});
const
textServer
=
this
.
add
.
text
(
width
/
2
,
height
/
2
+
40
,
'
Homeserver
'
,
{
fixedWidth
:
150
,
fixedHeight
:
36
});
textServer
.
setOrigin
(
0.5
,
0.5
);
textUserServer
.
setInteractive
().
on
(
'
pointerdown
'
,
function
()
{
console
.
log
(
this
);
this
.
scene
.
rexUI
.
edit
(
textServer
);
});
const
button
=
this
.
add
.
sprite
(
width
/
2
,
height
/
2
+
60
,
'
login
'
);
button
.
setOrigin
(
0.5
,
0
);
// button.setInteractive().on('pointerdown', function() {
// console.log(this);
// }
}
}
export
default
LoginScene
;
This diff is collapsed.
Click to expand it.
Nik | Klampfradler
@nik
mentioned in commit
305e7b00
·
4 years ago
mentioned in commit
305e7b00
mentioned in commit 305e7b002d83919ca1d2976fabfefcf5815e04d3
Toggle commit list
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment