Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
baas-ide
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
guxukai
baas-ide
Commits
e16c1061
Commit
e16c1061
authored
Jun 13, 2019
by
Grandschtroumpf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add alpha / beta warning in plugin manager
parent
044f140c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
26 additions
and
1 deletion
+26
-1
plugin-manager-component.js
src/app/components/plugin-manager-component.js
+26
-1
No files found.
src/app/components/plugin-manager-component.js
View file @
e16c1061
...
@@ -24,6 +24,9 @@ const css = csjs`
...
@@ -24,6 +24,9 @@ const css = csjs`
}
}
.displayName {
.displayName {
text-transform: capitalize;
text-transform: capitalize;
display: flex;
flex-direction: column;
align-items: flex-start;
}
}
.description {
.description {
text-transform: capitalize;
text-transform: capitalize;
...
@@ -36,6 +39,14 @@ const css = csjs`
...
@@ -36,6 +39,14 @@ const css = csjs`
background-color: var(--primary);
background-color: var(--primary);
color:
color:
}
}
.versionWarning {
background-color: var(--light);
padding: 0 7px;
font-weight: bolder;
margin-top: 5px;
text-transform: lowercase;
cursor: default;
}
`
`
const
profile
=
{
const
profile
=
{
...
@@ -82,6 +93,17 @@ class PluginManagerComponent extends BaseApi {
...
@@ -82,6 +93,17 @@ class PluginManagerComponent extends BaseApi {
const
isActive
=
this
.
store
.
actives
.
includes
(
name
)
const
isActive
=
this
.
store
.
actives
.
includes
(
name
)
const
displayName
=
(
api
.
profile
.
displayName
)
?
api
.
profile
.
displayName
:
name
const
displayName
=
(
api
.
profile
.
displayName
)
?
api
.
profile
.
displayName
:
name
// Check version of the plugin
let
versionWarning
// Alpha
if
(
api
.
profile
.
version
&&
api
.
profile
.
version
.
match
(
/
\b(\w
*alpha
\w
*
)\b
/g
))
{
versionWarning
=
yo
`<small title="Version Alpha" class="
${
css
.
versionWarning
}
">alpha</small>`
}
// Beta
if
(
api
.
profile
.
version
&&
api
.
profile
.
version
.
match
(
/
\b(\w
*beta
\w
*
)\b
/g
))
{
versionWarning
=
yo
`<small title="Version Beta" class="
${
css
.
versionWarning
}
">beta</small>`
}
const
activationButton
=
isActive
const
activationButton
=
isActive
?
yo
`
?
yo
`
<button onclick="
${
_
=>
this
.
appManager
.
deactivateOne
(
name
)}
" class="btn btn-secondary btn-sm">
<button onclick="
${
_
=>
this
.
appManager
.
deactivateOne
(
name
)}
" class="btn btn-secondary btn-sm">
...
@@ -95,7 +117,10 @@ class PluginManagerComponent extends BaseApi {
...
@@ -95,7 +117,10 @@ class PluginManagerComponent extends BaseApi {
return
yo
`
return
yo
`
<article id="remixPluginManagerListItem_
${
name
}
" class="list-group-item py-1" title="
${
displayName
}
" >
<article id="remixPluginManagerListItem_
${
name
}
" class="list-group-item py-1" title="
${
displayName
}
" >
<div class="
${
css
.
row
}
justify-content-between align-items-center">
<div class="
${
css
.
row
}
justify-content-between align-items-center">
<h6 class="
${
css
.
displayName
}
">
${
displayName
}
</h6>
<h6 class="
${
css
.
displayName
}
">
${
displayName
}
${
versionWarning
}
</h6>
${
activationButton
}
${
activationButton
}
</div>
</div>
<p class="
${
css
.
description
}
">
${
api
.
profile
.
description
}
</p>
<p class="
${
css
.
description
}
">
${
api
.
profile
.
description
}
</p>
...
...
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