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
1fa9f2f5
Commit
1fa9f2f5
authored
Feb 09, 2018
by
Iuri Matias
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
move renderer styles to its own file
parent
3ff4f621
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
60 additions
and
57 deletions
+60
-57
renderer.js
src/app/ui/renderer.js
+1
-57
renderer-styles.js
src/app/ui/styles/renderer-styles.js
+59
-0
No files found.
src/app/ui/renderer.js
View file @
1fa9f2f5
...
...
@@ -2,64 +2,8 @@
var
$
=
require
(
'jquery'
)
var
yo
=
require
(
'yo-yo'
)
var
css
=
require
(
'./styles/renderer-styles'
)
// -------------- styling ----------------------
// var csjs = require('csjs-inject')
var
styleGuide
=
require
(
'remix-lib'
).
ui
.
themeChooser
var
styles
=
styleGuide
.
chooser
()
var
css
=
yo
`<style>
.sol.success,
.sol.error,
.sol.warning {
word-wrap: break-word;
cursor: pointer;
position: relative;
margin: 0.5em 0 1em 0;
border-radius: 5px;
line-height: 20px;
padding: 8px 15px;
}
.sol.success pre,
.sol.error pre,
.sol.warning pre {
overflow-y: hidden;
background-color: transparent;
margin: 0;
font-size: 12px;
border: 0 none;
padding: 0;
border-radius: 0;
}
.sol.success .close,
.sol.error .close,
.sol.warning .close {
font-weight: bold;
position: absolute;
color: hsl(0, 0%, 0%); /* black in style-guide.js */
top: 0;
right: 0;
padding: 0.5em;
}
.sol.error {
background-color:
${
styles
.
rightPanel
.
message_Error_BackgroundColor
}
;
border: .2em dotted
${
styles
.
rightPanel
.
message_Error_BorderColor
}
;
color:
${
styles
.
rightPanel
.
message_Error_Color
}
;
}
.sol.warning {
background-color:
${
styles
.
rightPanel
.
message_Warning_BackgroundColor
}
;
color:
${
styles
.
rightPanel
.
message_Warning_Color
}
;
}
.sol.success {
background-color:
${
styles
.
rightPanel
.
message_Success_BackgroundColor
}
;
border: .2em dotted
${
styles
.
rightPanel
.
message_Success_BorderColor
}
;
color:
${
styles
.
rightPanel
.
message_Success_Color
}
;
}</style>`
/**
* After refactor, the renderer is only used to render error/warning
...
...
src/app/ui/styles/renderer-styles.js
0 → 100644
View file @
1fa9f2f5
var
yo
=
require
(
'yo-yo'
)
var
styleGuide
=
require
(
'remix-lib'
).
ui
.
themeChooser
var
styles
=
styleGuide
.
chooser
()
var
css
=
yo
`<style>
.sol.success,
.sol.error,
.sol.warning {
word-wrap: break-word;
cursor: pointer;
position: relative;
margin: 0.5em 0 1em 0;
border-radius: 5px;
line-height: 20px;
padding: 8px 15px;
}
.sol.success pre,
.sol.error pre,
.sol.warning pre {
overflow-y: hidden;
background-color: transparent;
margin: 0;
font-size: 12px;
border: 0 none;
padding: 0;
border-radius: 0;
}
.sol.success .close,
.sol.error .close,
.sol.warning .close {
font-weight: bold;
position: absolute;
color: hsl(0, 0%, 0%); /* black in style-guide.js */
top: 0;
right: 0;
padding: 0.5em;
}
.sol.error {
background-color:
${
styles
.
rightPanel
.
message_Error_BackgroundColor
}
;
border: .2em dotted
${
styles
.
rightPanel
.
message_Error_BorderColor
}
;
color:
${
styles
.
rightPanel
.
message_Error_Color
}
;
}
.sol.warning {
background-color:
${
styles
.
rightPanel
.
message_Warning_BackgroundColor
}
;
color:
${
styles
.
rightPanel
.
message_Warning_Color
}
;
}
.sol.success {
background-color:
${
styles
.
rightPanel
.
message_Success_BackgroundColor
}
;
border: .2em dotted
${
styles
.
rightPanel
.
message_Success_BorderColor
}
;
color:
${
styles
.
rightPanel
.
message_Success_Color
}
;
}</style>`
module
.
exports
=
css
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