Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
rendezvous
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
VeNtura
rendezvous
Commits
4da1e1c4
Commit
4da1e1c4
authored
Nov 07, 2014
by
tady
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix split editor
parent
d2705349
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
52 additions
and
52 deletions
+52
-52
app/assets/javascripts/modules/mod-form-resizes.js.coffee
+1
-1
app/views/posts/_form.html.slim
+51
-51
No files found.
app/assets/javascripts/modules/mod-form-resizes.js.coffee
View file @
4da1e1c4
...
...
@@ -15,7 +15,7 @@ $.extend
$window
=
$
(
window
)
editor_height
=
0
settings
.
$preview
.
css
(
'overflow
-y
'
,
'scroll'
)
settings
.
$preview
.
css
(
'overflow'
,
'scroll'
)
# Set editor & preview height
adjustHeight
=
->
...
...
app/views/posts/_form.html.slim
View file @
4da1e1c4
...
...
@@ -30,55 +30,55 @@
p
.actions
=
f
.
date_select
:specified_date
table
tr
td
.editor-panel
.panel.panel-default
.panel-heading
.btn-toolbar
role
=
"toolbar"
.btn-group.btn-group-xs
button
.btn.btn-default.mod-mdEditor-btn-h1
type
=
"button"
title
=
"Header level 1"
H1
button
.btn.btn-default.mod-mdEditor-btn-h2
type
=
"button"
title
=
"Header level 2"
H2
button
.btn.btn-default.mod-mdEditor-btn-h3
type
=
"button"
title
=
"Header level 3"
H3
.btn-group.btn-group-xs
button
.btn.btn-default.mod-mdEditor-btn-bold
type
=
"button"
title
=
"Text bold"
i
.fa.fa-bold
button
.btn.btn-default.mod-mdEditor-btn-italic
type
=
"button"
title
=
"Text itelic"
i
.fa.fa-italic
.btn-group.btn-group-xs
button
.btn.btn-default.mod-mdEditor-btn-ol
type
=
"button"
title
=
"順序リスト"
i
.fa.fa-list-ol
button
.btn.btn-default.mod-mdEditor-btn-ul
type
=
"button"
title
=
"リスト"
i
.fa.fa-list-ul
button
.btn.btn-default.mod-mdEditor-btn-strikethrough
type
=
"button"
title
=
"打ち消し線"
i
.fa.fa-strikethrough
.btn-group.btn-group-xs
button
#uploadButton
.btn.btn-default
type
=
"button"
title
=
"Upload"
|
Upload
.btn-group.btn-group-xs.pull-right.mode-editor
button
#uploadButton
.btn.btn-default
type
=
"button"
i
.fa.fa-angle-right
.btn-group.btn-group-xs.pull-right.mode-split
style
=
"display:none"
button
#uploadButton
.btn.btn-default
type
=
"button"
i
.fa.fa-angle-left
.panel-body.panel-body-nopadding
style
=
"position:relative"
=
f
.
text_area
:body
,
class:
'mod-mdEditor-textarea mod-form-resizer-editor'
,
placehoder:
'type your text....'
#progress-wrapper
style
=
"display:none;position:absolute;bottom:0;z-index:1000;width:100%"
.alert.alert-warning.fade.in
style
=
"margin-bottom:0"
span
.progress-title
|
Uploading files...
#progress
style
=
"height:20px;"
.progress-bar.progress-bar-success.progress-bar-striped.active
role
=
"progressbar"
aria-valuemin
=
"0"
aria-valuemax
=
"100"
style
=
"width: 0%;"
|
0%
td
.preview-panel
.panel.preview-wrapper
.panel-heading
span
Preview
.panel-body.text-box.body.viewer.github.mod-mdEditor-preview.mod-form-resizer-preview
.row
.col-xs-6
.editor-panel
.panel.panel-default
.panel-heading
.btn-toolbar
role
=
"toolbar"
.btn-group.btn-group-xs
button
.btn.btn-default.mod-mdEditor-btn-h1
type
=
"button"
title
=
"Header level 1"
H1
button
.btn.btn-default.mod-mdEditor-btn-h2
type
=
"button"
title
=
"Header level 2"
H2
button
.btn.btn-default.mod-mdEditor-btn-h3
type
=
"button"
title
=
"Header level 3"
H3
.btn-group.btn-group-xs
button
.btn.btn-default.mod-mdEditor-btn-bold
type
=
"button"
title
=
"Text bold"
i
.fa.fa-bold
button
.btn.btn-default.mod-mdEditor-btn-italic
type
=
"button"
title
=
"Text itelic"
i
.fa.fa-italic
.btn-group.btn-group-xs
button
.btn.btn-default.mod-mdEditor-btn-ol
type
=
"button"
title
=
"順序リスト"
i
.fa.fa-list-ol
button
.btn.btn-default.mod-mdEditor-btn-ul
type
=
"button"
title
=
"リスト"
i
.fa.fa-list-ul
button
.btn.btn-default.mod-mdEditor-btn-strikethrough
type
=
"button"
title
=
"打ち消し線"
i
.fa.fa-strikethrough
.btn-group.btn-group-xs
button
#uploadButton
.btn.btn-default
type
=
"button"
title
=
"Upload"
|
Upload
.btn-group.btn-group-xs.pull-right.mode-editor
button
#uploadButton
.btn.btn-default
type
=
"button"
i
.fa.fa-angle-right
.btn-group.btn-group-xs.pull-right.mode-split
style
=
"display:none"
button
#uploadButton
.btn.btn-default
type
=
"button"
i
.fa.fa-angle-left
.panel-body.panel-body-nopadding
style
=
"position:relative"
=
f
.
text_area
:body
,
class:
'mod-mdEditor-textarea mod-form-resizer-editor'
,
placehoder:
'type your text....'
#progress-wrapper
style
=
"display:none;position:absolute;bottom:0;z-index:1000;width:100%"
.alert.alert-warning.fade.in
style
=
"margin-bottom:0"
span
.progress-title
|
Uploading files...
#progress
style
=
"height:20px;"
.progress-bar.progress-bar-success.progress-bar-striped.active
role
=
"progressbar"
aria-valuemin
=
"0"
aria-valuemax
=
"100"
style
=
"width: 0%;"
|
0%
.col-xs-6
.preview-panel
.panel.preview-wrapper
.panel-heading
span
Preview
.panel-body.text-box.body.viewer.github.mod-mdEditor-preview.mod-form-resizer-preview
input
#fileupload
data-url
=
"/apis/file_receiver"
multiple
=
""
name
=
"files[]"
style
=
"display:none"
type
=
"file"
/
...
...
@@ -91,12 +91,12 @@ input#fileupload data-url="/apis/file_receiver" multiple="" name="files[]" style
$
(
'.mode-editor button'
).
on
(
'click'
,
function
(){
$
(
'.mode-editor'
).
hide
();
$
(
'.mode-split'
).
show
();
$
(
'.editor-panel'
).
css
(
'width'
,
'100%'
);
$
(
'.editor-panel'
).
show
(
);
$
(
'.preview-panel'
).
hide
();
$
(
'.editor-panel'
).
addClass
(
'col-xs-12'
).
removeClass
(
'col-xs-6'
);
$
(
'.preview-panel'
).
hide
();
})
$
(
'.mode-split button'
).
on
(
'click'
,
function
(){
$
(
'.mode-split'
).
hide
();
$
(
'.mode-editor'
).
show
();
$
(
'.editor-panel'
).
css
(
'width'
,
'50%'
);
$
(
'.preview-panel'
).
css
(
'width'
,
'50%'
);
$
(
'.editor-panel'
).
show
(
);
$
(
'.preview-panel'
).
show
();
$
(
'.editor-panel'
).
addClass
(
'col-xs-6'
).
removeClass
(
'col-xs-12'
);
$
(
'.preview-panel'
).
show
();
})
$
(
'#post-form'
).
mod_mdEditor
({
end_point
:
'/apis/markdown_preview'
});
...
...
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