Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Maxime Besson
lemonldap-ng
Commits
7529b9cc
Commit
7529b9cc
authored
Mar 30, 2016
by
Yadd
Browse files
Portal js skeleton (#595)
parent
786f1c42
Changes
4
Hide whitespace changes
Inline
Side-by-side
Makefile
View file @
7529b9cc
...
...
@@ -186,12 +186,12 @@ MANAGERJSONDST=$(SRCMANAGERDIR)/site/static/struct.json \
_example/conf/lmConf-1.js
# Javascript and CSS to minify
JSSRCFILES
:=
$(
shell
find
$(SRCMANAGERDIR)
/site/static/js
$(SRCPORTALDIR)
/example
-type
f
-name
'*.js'
!
-name
'*.min.js'
)
\
JSSRCFILES
:=
$(
shell
find
*
/site/static/js
$(SRCPORTALDIR)
/example
-type
f
-name
'*.js'
!
-name
'*.min.js'
)
\
$(SRCMANAGERDIR)
/site/static/bwr/file-saver.js/FileSaver.js
CSSSRCFILES
:=
$(
shell
find
$(SRCMANAGERDIR)
/site/static/css
$(SRCPORTALDIR)
/example
-type
f
-name
'*.css'
!
-name
'*.min.css'
)
CSSSRCFILES
:=
$(
shell
find
*
/site/static/css
$(SRCPORTALDIR)
/example
-type
f
-name
'*.css'
!
-name
'*.min.css'
)
# Coffee files
COFFEESRCFILES
:=
$(
shell
find
$(SRCMANAGERDIR)
/site/coffee/
-type
f
-name
'*.coffee'
)
COFFEESRCFILES
:=
$(
shell
find
*
/site/coffee/
-type
f
-name
'*.coffee'
)
COFFEEDSTFILES
:=
$(
subst
coffee/,static/js/,
$(COFFEESRCFILES:.coffee=.js)
)
# Minified files
...
...
@@ -264,6 +264,12 @@ js: $(COFFEEDSTFILES)
minify
:
js $(JSDSTFILES) $(CSSDSTFILES)
$(SRCPORTALDIR)/site/static/js/%.js
:
$(SRCPORTALDIR)/site/coffee/%.coffee
@
if
which coffee
>
/dev/null
;
then
\
echo
"Compiling
$(SRCPORTALDIR)
/site/coffee/
$*
.coffee"
;
\
coffee
-c
-o
$(SRCPORTALDIR)
/site/static/js/
$(SRCPORTALDIR)
/site/coffee/
$*
.coffee
;
\
fi
$(SRCMANAGERDIR)/site/static/js/%.js
:
$(SRCMANAGERDIR)/site/coffee/%.coffee
@
if
which coffee
>
/dev/null
;
then
\
echo
"Compiling
$(SRCMANAGERDIR)
/site/coffee/
$*
.coffee"
;
\
...
...
lemonldap-ng-portal/site/coffee/portal.coffee
0 → 100644
View file @
7529b9cc
window
.
translatePage
=
(
lang
)
->
$
(
"[trspan]"
).
each
->
this
.
text
translate
this
.
attr
'trspan'
$
(
document
).
ready
->
translatePage
(
lang
)
lemonldap-ng-portal/site/static/js/portal.js
0 → 100644
View file @
7529b9cc
// Generated by CoffeeScript 1.10.0
(
function
()
{
window
.
translatePage
=
function
(
lang
)
{
return
$
(
"
[trspan]
"
).
each
(
function
()
{
return
this
.
text
(
translate
(
this
.
attr
(
'
trspan
'
)));
});
};
$
(
document
).
ready
(
function
()
{
return
translatePage
(
lang
);
});
}).
call
(
this
);
lemonldap-ng-portal/site/static/js/portal.min.js
0 → 100644
View file @
7529b9cc
(
function
(){
window
.
translatePage
=
function
(
a
){
return
$
(
"
[trspan]
"
).
each
(
function
(){
return
this
.
text
(
translate
(
this
.
attr
(
"
trspan
"
)))})};
$
(
document
).
ready
(
function
(){
return
translatePage
(
lang
)})}).
call
(
this
);
\ No newline at end of file
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment