Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
scripta
eScriptorium
Commits
7cf307b6
Commit
7cf307b6
authored
Oct 23, 2020
by
Robin Tissot
Browse files
Code cleanup.
parent
25be2490
Changes
5
Hide whitespace changes
Inline
Side-by-side
app/apps/core/static/js/edit/components/trans_modal.js
View file @
7cf307b6
...
...
@@ -26,10 +26,6 @@ const TranscriptionModal = Vue.component('transcriptionmodal', {
$
(
this
.
$el
).
draggable
({
handle
:
'
.modal-header
'
});
$
(
this
.
$el
).
resizable
();
this
.
computeStyles
();
let
timer
=
setTimeout
(
function
(){
this
.
show_onboarding
();
}.
bind
(
this
),
1000
);
},
watch
:
{
line
(
new_
,
old_
)
{
...
...
@@ -167,25 +163,6 @@ const TranscriptionModal = Vue.component('transcriptionmodal', {
}
else
{
overlay
.
style
.
display
=
'
none
'
;
}
},
show_onboarding
(){
if
(
onboarding
==
"
True
"
&&
!
onboarding_trans
)
{
this
.
intro
=
introJs
();
this
.
intro
.
setOptions
({
steps
:
steps_trans
});
this
.
intro
.
start
();
this
.
intro
.
onexit
(
function
()
{
userProfile
.
set
(
'
onboarding_trans
'
,
true
);
exitonboarding
();
});
this
.
intro
.
oncomplete
(
function
()
{
userProfile
.
set
(
'
onboarding_trans
'
,
true
);
exitonboarding
();
});
}
}
},
});
app/apps/core/static/js/edit/main.js
View file @
7cf307b6
...
...
@@ -13,8 +13,7 @@ var partVM = new Vue({
blockShortcuts
:
false
,
fullsizeimage
:
false
,
selectedTranscription
:
null
,
comparedTranscriptions
:
[],
intro
:
introJs
()
comparedTranscriptions
:
[]
},
computed
:
{
imageSize
()
{
...
...
@@ -178,9 +177,6 @@ var partVM = new Vue({
}.
bind
(
this
));
},
methods
:
{
show_onboarding
(){
},
resetZoom
()
{
this
.
zoom
.
reset
();
},
...
...
app/apps/users/views.py
View file @
7cf307b6
...
...
@@ -102,7 +102,6 @@ class Profile(SuccessMessageMixin, UpdateView):
page_number
=
self
.
request
.
GET
.
get
(
'page'
)
context
[
'is_paginated'
]
=
paginator
.
count
!=
0
context
[
'page_obj'
]
=
paginator
.
get_page
(
page_number
)
context
[
'onboarding'
]
=
self
.
request
.
user
.
onboarding
return
context
...
...
app/escriptorium/templates/base.html
View file @
7cf307b6
...
...
@@ -113,8 +113,8 @@
<script
src=
"{% static 'js/messages.js' %}"
></script>
{% include 'includes/messages.html' %}
<script
src=
"{% static 'js/profile.js' %}"
></script>
<script
src=
"{% static 'vendor/introjs/intro.js' %}"
></script>
{% if user.onboarding %}
<script
src=
"{% static 'vendor/introjs/intro.js' %}"
></script>
<script
src=
"{% static 'js/onboarding.js' %}"
></script>
{% endif %}
{% endif %}
...
...
app/escriptorium/templates/core/document_images.html
View file @
7cf307b6
...
...
@@ -113,9 +113,11 @@
{% block scripts %}
<script
type=
"text/javascript"
>
'
use strict
'
;
const
DOCUMENT_ID
=
{{
document
.
pk
}};
const
ONBOARDING_PAGE
=
'
onboarding_images
'
;
'
use strict
'
;
const
DOCUMENT_ID
=
{{
document
.
pk
}};
{
%
if
user
.
onboarding
%
}
const
ONBOARDING_PAGE
=
'
onboarding_images
'
;
{
%
endif
%
}
</script>
{{ block.super }}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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