Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Knowledge Space WP Plugin
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container 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
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
alg
Knowledge Space WP Plugin
Commits
88819792
Commit
88819792
authored
3 years ago
by
Matthias Konitzny
Browse files
Options
Downloads
Plain Diff
Merge branch 'master' into gitlab-ci
parents
26ffc5d4
923e0576
No related branches found
No related tags found
No related merge requests found
Pipeline
#49466
failed
3 years ago
Stage: test
Stage: build
Stage: deploy
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
config.js
+2
-0
2 additions, 0 deletions
config.js
datasets/datasets.js
+9
-6
9 additions, 6 deletions
datasets/datasets.js
knowledge-space.php
+2
-2
2 additions, 2 deletions
knowledge-space.php
with
13 additions
and
8 deletions
config.js
+
2
−
0
View file @
88819792
/*global ks_global*/
export
const
COLOR_PALETTE
=
[
"
rgb(104, 169, 77)
"
,
"
rgb(102, 75, 154)
"
,
...
...
This diff is collapsed.
Click to expand it.
datasets/datasets.js
+
9
−
6
View file @
88819792
import
{
PLUGIN_PATH
}
from
"
../config
"
;
/*global ks_global*/
import
jQuery
from
"
jquery
"
;
/**
...
...
@@ -55,9 +56,11 @@ export function listAllSpaces() {
action
:
"
list_spaces
"
,
};
return
jQuery
.
ajax
({
type
:
"
POST
"
,
url
:
ks_global
.
ajax_url
,
data
:
payload
,
}).
then
((
data
)
=>
JSON
.
parse
(
data
)[
"
spaces
"
]);
return
jQuery
.
ajax
({
type
:
"
POST
"
,
url
:
ks_global
.
ajax_url
,
data
:
payload
,
})
.
then
((
data
)
=>
JSON
.
parse
(
data
)[
"
spaces
"
]);
}
This diff is collapsed.
Click to expand it.
knowledge-space.php
+
2
−
2
View file @
88819792
...
...
@@ -15,7 +15,7 @@ function ks_add_graph($atts = []): string
$script_path
=
'build'
.
DIRECTORY_SEPARATOR
.
$GLOBALS
[
'build'
]
.
DIRECTORY_SEPARATOR
.
'graph.js'
;
wp_enqueue_script
(
"ks-display-js"
,
plugins_url
(
$script_path
,
__FILE__
),
array
(
'jquery'
),
false
);
ks_localize
(
"ks-display-js"
);
ks_localize
(
"ks-display-js"
,
$atts
);
return
$div
;
}
...
...
@@ -25,7 +25,7 @@ function ks_echo_graph($atts = []): void
echo
ks_add_graph
(
$atts
);
}
function
ks_localize
(
$handle
)
function
ks_localize
(
$handle
,
$atts
)
{
$space_id
=
kg_get_space_id_from_atts
(
$atts
);
$plugin_dir
=
plugin_dir_url
(
__FILE__
);
...
...
This diff is collapsed.
Click to expand it.
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