Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
AdminLTE renderer
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
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
IML Open Source
AdminLTE renderer
Commits
de933feb
Commit
de933feb
authored
2 years ago
by
Hahn Axel (hahn)
Browse files
Options
Downloads
Patches
Plain Diff
compnents: add card testing
parent
85634d79
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
public_html/inc_functions.php
+18
-12
18 additions, 12 deletions
public_html/inc_functions.php
public_html/pages/component.php
+45
-4
45 additions, 4 deletions
public_html/pages/component.php
public_html/ui/main.css
+3
-1
3 additions, 1 deletion
public_html/ui/main.css
with
66 additions
and
17 deletions
public_html/inc_functions.php
+
18
−
12
View file @
de933feb
...
...
@@ -18,21 +18,27 @@ function showExample($sPhpcode){
<tr>
<th>Source</th>
<th>Output</th>
<th>Generated html code</th>
</tr>
</thead>
<tbody>
<tr>
<td>
<div class="language-php max-height-300 highlighter-rouge"><div class="highlight">
<pre class="highlight">'
.
htmlentities
(
$sPhpcode
)
.
'</pre>
</div></div>
<pre class="highlight">'
.
str_replace
(
[
'array ('
,
'))'
],
[
'array (<span class="params">'
,
'</span>))'
],
htmlentities
(
$sPhpcode
))
.
'</pre>
</td>
<td>
'
.
$sOut
.
'
</td>
<td>
<pre>'
.
htmlentities
(
str_replace
([
">"
,
"</"
,
"
\n\n
"
],
[
">
\n
"
,
"
\n
</"
,
"
\n
"
],
$sOut
))
.
'</pre>
'
.
$sOut
.
'<br><br>
<pre>'
.
str_replace
(
[
'>'
,
'<'
],
[
'><span class="output">'
,
'</span><'
],
htmlentities
(
str_replace
([
">"
,
"</"
,
"
\n\n
"
],
[
">
\n
"
,
"
\n
</"
,
"
\n
"
],
$sOut
))
)
.
'</pre>
</td>
</tr>
</tbody>
...
...
This diff is collapsed.
Click to expand it.
public_html/pages/component.php
+
45
−
4
View file @
de933feb
...
...
@@ -54,6 +54,23 @@ $aPresets=[
'xs'
=>
''
,
'flat'
=>
''
,
],
'variant'
=>
[
''
=>
'no value'
,
'outline'
=>
'small stripe on top'
,
'solid'
=>
''
,
'gradient'
=>
''
,
],
'visibility'
=>
[
''
=>
'no value'
,
'0'
=>
'hide'
,
'1'
=>
'show'
,
],
// for keys: state
'windowstate'
=>
[
''
=>
'no value'
,
'collapsed'
=>
'header only'
,
'maximized'
=>
'full window'
,
],
// for keys: dismissable
'yesno'
=>
[
''
=>
'no value'
,
...
...
@@ -76,8 +93,8 @@ $aComponents=[
'params'
=>
[
'type'
=>
[
'select'
=>
$aPresets
[
'type'
],
'default'
=>
'warning'
],
'dismissible'
=>
[
'select'
=>
$aPresets
[
'yesno'
],
'default'
=>
''
],
'title'
=>
[
'default'
=>
'
I need your attention
'
],
'text'
=>
[
'default'
=>
'
Please check it. Maybe there is something wrong her
e.'
],
'title'
=>
[
'default'
=>
'
Alert title
'
],
'text'
=>
[
'default'
=>
'
I am a message. Read me, pleas
e.'
],
]
],
// ------------------------------------------------------------
...
...
@@ -121,6 +138,30 @@ $aComponents=[
]
],
// ------------------------------------------------------------
'card'
=>
[
'label'
=>
'Callout'
,
'description'
=>
'Content box with header, text, footer'
,
'method'
=>
'getCard'
,
'params'
=>
[
'variant'
=>
[
'select'
=>
$aPresets
[
'variant'
],
'default'
=>
''
],
'type'
=>
[
'select'
=>
$aPresets
[
'type'
],
'default'
=>
'danger'
],
'class'
=>
[
'default'
=>
''
],
'state'
=>
[
'select'
=>
$aPresets
[
'windowstate'
],
'default'
=>
''
],
'tb-collapse'
=>
[
'select'
=>
$aPresets
[
'visibility'
],
'default'
=>
''
],
'tb-expand'
=>
[
'select'
=>
$aPresets
[
'visibility'
],
'default'
=>
''
],
'tb-maximize'
=>
[
'select'
=>
$aPresets
[
'visibility'
],
'default'
=>
''
],
'tb-minimize'
=>
[
'select'
=>
$aPresets
[
'visibility'
],
'default'
=>
''
],
'tb-remove'
=>
[
'select'
=>
$aPresets
[
'visibility'
],
'default'
=>
''
],
'title'
=>
[
'default'
=>
'I am a card'
],
'tools'
=>
[
'default'
=>
'Tools'
],
'text'
=>
[
'default'
=>
'Here is some beautiful content.'
],
'footer'
=>
[
'default'
=>
'Footer'
],
]
],
// ------------------------------------------------------------
'infobox'
=>
[
'label'
=>
'Infobox'
,
'description'
=>
''
,
...
...
@@ -179,8 +220,8 @@ if(!isset($aComponents[$sComponent])){
.
(
$sValue
==
$sSelectItem
?
' selected="selected"'
:
''
)
.
'>'
.
$sSelectItem
.
' -> '
.
$sLabel
.
'</option>'
;
}
$sInput
=
'<select size="1" name="'
.
$sOptionkey
.
'" onchange="form.submit();">'
.
$sInput
.
'</select>'
.
' <button name="doloop" value="'
.
$sOptionkey
.
'">Loop</button><br>'
;
$sInput
=
'<
nobr><
select size="1" name="'
.
$sOptionkey
.
'" onchange="form.submit();">'
.
$sInput
.
'</select>'
.
' <button name="doloop" value="'
.
$sOptionkey
.
'">Loop</button><
no
br>'
;
}
else
{
...
...
This diff is collapsed.
Click to expand it.
public_html/ui/main.css
+
3
−
1
View file @
de933feb
pre
{
background-color
:
#445
;
color
:
#f8f8f8
}
;
\ No newline at end of file
pre
{
background-color
:
#445
;
color
:
#f8f8f8
}
pre
.params
{
color
:
#acc
}
pre
.output
{
color
:
#aaf
}
\ No newline at end of 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