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
dariah
search-commons-webresources
Commits
8a08601d
Commit
8a08601d
authored
Feb 13, 2018
by
Gradl, Tobias
Browse files
598: Implement CustomSearch as successor of user collections
Task-Url:
https://pm.winseda.de/issues/598
parent
19ffe474
Changes
1
Hide whitespace changes
Inline
Side-by-side
js/home.js
View file @
8a08601d
var
home
;
$
(
document
).
ready
(
function
()
{
home
=
new
Home
({});
home
=
new
Home
({
tagUrlPrefix
:
$
(
"
#custom-prefix
"
).
val
()
});
home
.
loadWordcloud
();
});
var
Home
=
function
(
options
)
{
this
.
options
=
$
.
extend
({
wordcloud
:
{
selector
:
"
.wordcloud
"
,
tagUrlPrefix
:
""
,
animate
:
true
,
animateDirection
:
"
topDown
"
,
height
:
500
,
...
...
@@ -29,7 +32,7 @@ Home.prototype.handleTagTextClicked = function(tag) {
Home
.
prototype
.
loadWordcloud
=
function
()
{
var
_this
=
this
;
$
.
ajax
({
url
:
__util
.
composeUrl
(
"
tags?analyzer=
"
+
_this
.
options
.
analyzer
+
"
&size=
"
+
_this
.
options
.
tagcount
),
url
:
__util
.
composeUrl
(
_this
.
options
.
tagUrlPrefix
+
"
/
tags?analyzer=
"
+
_this
.
options
.
analyzer
+
"
&size=
"
+
_this
.
options
.
tagcount
),
type
:
"
GET
"
,
dataType
:
"
json
"
,
success
:
function
(
data
)
{
_this
.
fillWordcloud
(
data
);
},
...
...
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