Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
Linnea Samila
/
Moya
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 8c372a50
authored
May 14, 2017
by
Tuukka Kivilahti
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
some stuff before lint
1 parent
2eabd5d2
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
80 additions
and
12 deletions
code/moya-angular/angular-cli.json
code/moya-angular/src/app/app.component.css
code/moya-angular/src/app/app.module.ts
code/moya-angular/src/app/menu/top-menu/top-menu.component.css
code/moya-angular/src/app/menu/top-menu/top-menu.component.html
code/moya-angular/src/app/old-moya/old-moya.component.css
code/moya-angular/src/app/old-moya/old-moya.component.html
code/moya-angular/src/app/old-moya/old-moya.component.ts
code/moya-angular/src/styles.css
code/moya-angular/angular-cli.json
View file @
8c372a5
...
@@ -18,8 +18,8 @@
...
@@ -18,8 +18,8 @@
"prefix"
:
"app"
,
"prefix"
:
"app"
,
"mobile"
:
false
,
"mobile"
:
false
,
"styles"
:
[
"styles"
:
[
"
styles
.css"
,
"
../node_modules/bootstrap/dist/css/bootstrap.min
.css"
,
"
../node_modules/bootstrap/dist/css/bootstrap.min
.css"
"
styles
.css"
],
],
"scripts"
:
[],
"scripts"
:
[],
"environmentSource"
:
"environments/environment.ts"
,
"environmentSource"
:
"environments/environment.ts"
,
...
@@ -57,5 +57,10 @@
...
@@ -57,5 +57,10 @@
"pipe"
:
true
,
"pipe"
:
true
,
"service"
:
true
"service"
:
true
}
}
},
"lint"
:
[
{
"project"
:
"src/tsconfig.json"
}
}
]
}
}
code/moya-angular/src/app/app.component.css
View file @
8c372a5
#top-container
{
#top-container
{
width
:
100%
;
display
:
flex
;
display
:
flex
;
}
}
...
@@ -16,9 +17,11 @@
...
@@ -16,9 +17,11 @@
}
}
#topbar
{
#topbar
{
border
:
1px
solid
red
;
margin-bottom
:
30px
;
}
}
#content
{
#content
{
border
:
1px
solid
yellow
;
border
:
1px
solid
yellow
;
display
:
flex
;
flex-direction
:
row
;
}
}
code/moya-angular/src/app/app.module.ts
View file @
8c372a5
...
@@ -33,7 +33,7 @@ const appRoutes: Routes = [
...
@@ -33,7 +33,7 @@ const appRoutes: Routes = [
{
path
:
'info'
,
{
path
:
'info'
,
children
:
[
children
:
[
{
path
:
''
,
component
:
InfoMenuComponent
,
outlet
:
"left-menu"
},
{
path
:
''
,
component
:
InfoMenuComponent
,
outlet
:
"left-menu"
},
{
path
:
''
,
pathMatch
:
'full'
,
component
:
Info
Component
},
{
path
:
''
,
pathMatch
:
'full'
,
component
:
OldMoya
Component
},
{
path
:
'old'
,
component
:
OldMoyaComponent
},
{
path
:
'old'
,
component
:
OldMoyaComponent
},
]
]
},
},
...
...
code/moya-angular/src/app/menu/top-menu/top-menu.component.css
View file @
8c372a5
#topNav
{
padding
:
10px
10px
10px
30px
;
display
:
flex
;
background-color
:
white
;
}
.topNavItem
{
display
:
inline-block
;
padding
:
10px
20px
10px
20px
;
margin-right
:
10px
;
font-family
:
Roboto
;
font-size
:
14px
;
color
:
#FFFFFF
;
letter-spacing
:
0
;
opacity
:
0.5
;
min-width
:
100px
;
text-align
:
center
;
}
.topNavItem.active
{
opacity
:
1.0
;
}
#userTopNav
{
background
:
#2b2c3a
;
}
#infoTopNav
{
background
:
#de821f
;
}
#adminTopNav
{
background
:
#69B1A1
;
}
code/moya-angular/src/app/menu/top-menu/top-menu.component.html
View file @
8c372a5
<nav>
<nav
id=
"topNav"
>
<a
class=
"topNavItem"
id=
"userTopNav"
routerLink=
"/user"
routerLinkActive=
"active"
i18n
>
USER
</a>
<a
class=
"topNavItem"
id=
"userTopNav"
routerLink=
"/user"
routerLinkActive=
"active"
i18n
>
Kävijänäkymä
</a>
<a
class=
"topNavItem"
id=
"infoTopNav"
routerLink=
"/info"
routerLinkActive=
"active"
i18n
>
INFO
</a>
<a
class=
"topNavItem"
id=
"infoTopNav"
routerLink=
"/info"
routerLinkActive=
"active"
[
queryParams
]="{
p:
'
useradmin
/
list
.
jsf
'}"
i18n
>
Infonäkymä
</a>
<a
class=
"topNavItem"
id=
"adminTopNav"
routerLink=
"/admin"
routerLinkActive=
"active"
i18n
>
ADMIN
</a>
<a
class=
"topNavItem"
id=
"adminTopNav"
routerLink=
"/admin"
routerLinkActive=
"active"
i18n
>
Ylläpitonäkymä
</a>
</nav>
</nav>
code/moya-angular/src/app/old-moya/old-moya.component.css
View file @
8c372a5
:host
{
display
:
flex
;
flex-grow
:
1
;
}
#oldMoyaFrame
{
flex-grow
:
1
;
}
code/moya-angular/src/app/old-moya/old-moya.component.html
View file @
8c372a5
<iframe
[
src
]="
frameUrl
|
safe
"
width=
"100%"
[
height
]="
height
"
#
iframe
(
load
)="
changeUrl
()"
frameborder=
"0"
></iframe><br
/
>
<iframe
id=
"oldMoyaFrame"
[
src
]="
frameUrl
|
safe
"
[
height
]="
height
"
#
iframe
(
load
)="
changeUrl
()"
frameborder=
"0"
></iframe
>
code/moya-angular/src/app/old-moya/old-moya.component.ts
View file @
8c372a5
...
@@ -4,7 +4,7 @@ import {NavigationExtras, ActivatedRoute, Router} from "@angular/router";
...
@@ -4,7 +4,7 @@ import {NavigationExtras, ActivatedRoute, Router} from "@angular/router";
import
{
Observable
}
from
"rxjs"
;
import
{
Observable
}
from
"rxjs"
;
@
Component
({
@
Component
({
selector
:
'
app-
old-moya'
,
selector
:
'old-moya'
,
providers
:
[
Location
,
{
provide
:
LocationStrategy
,
useClass
:
PathLocationStrategy
}],
providers
:
[
Location
,
{
provide
:
LocationStrategy
,
useClass
:
PathLocationStrategy
}],
templateUrl
:
'./old-moya.component.html'
,
templateUrl
:
'./old-moya.component.html'
,
styleUrls
:
[
'./old-moya.component.css'
]
styleUrls
:
[
'./old-moya.component.css'
]
...
@@ -17,7 +17,7 @@ export class OldMoyaComponent implements OnInit {
...
@@ -17,7 +17,7 @@ export class OldMoyaComponent implements OnInit {
@
ViewChild
(
'iframe'
)
iframe
:
any
;
@
ViewChild
(
'iframe'
)
iframe
:
any
;
height
:
string
=
"
10
00px"
;
height
:
string
=
"
7
00px"
;
...
@@ -41,9 +41,13 @@ export class OldMoyaComponent implements OnInit {
...
@@ -41,9 +41,13 @@ export class OldMoyaComponent implements OnInit {
this
.
location
.
replaceState
(
this
.
location
.
path
(
false
).
split
(
"?"
,
1
)[
0
]
+
"?p="
+
tmpFrameUrl
[
1
]);
this
.
location
.
replaceState
(
this
.
location
.
path
(
false
).
split
(
"?"
,
1
)[
0
]
+
"?p="
+
tmpFrameUrl
[
1
]);
}
}
console
.
log
(
this
.
iframe
.
nativeElement
.
contentWindow
.
document
.
body
.
height
);
this
.
height
=
this
.
iframe
.
nativeElement
.
contentWindow
.
document
.
body
.
scrollHeight
+
"px"
;
this
.
height
=
this
.
iframe
.
nativeElement
.
contentWindow
.
document
.
body
.
scrollHeight
+
"px"
;
console
.
log
(
this
.
height
);
}
}
...
...
code/moya-angular/src/styles.css
View file @
8c372a5
/* You can add global styles to this file, and also import other style files */
/* You can add global styles to this file, and also import other style files */
@import
url('https://fonts.googleapis.com/css?family=Roboto')
;
@import
'~@angular/material/prebuilt-themes/indigo-pink.css'
;
@import
'~@angular/material/prebuilt-themes/indigo-pink.css'
;
body
{
background-color
:
#f2f3f9
;
}
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment