Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change some style that supported by Bootstrap 4 #296

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions bower.json
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
{
"name": "bootstrap-markdown",
"version": "2.10.0",
"main": ["./js/bootstrap-markdown.js", "./css/bootstrap-markdown.min.css"],
"main": [
"./js/bootstrap-markdown.js",
"./css/bootstrap-markdown.min.css"
],
"license": "Apache-2.0",
"dependencies": {
"bootstrap": "~3"
"bootstrap": "v4.0.0-alpha.6"
},
"devDependencies": {
"markdown":"~0.4.0"
"markdown": "~0.4.0"
}
}
20 changes: 4 additions & 16 deletions js/bootstrap-markdown.js
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@
var z,
buttons = btnGroups[y].data,
btnGroupContainer = $('<div/>', {
'class': 'btn-group'
'class': 'btn-group mr-2'
});

for (z = 0; z < buttons.length; z++) {
Expand All @@ -122,9 +122,9 @@

// Construct the button object
buttonContainer = $('<button></button>');
buttonContainer.text(' ' + this.__localize(btnText)).addClass('btn-default btn-sm').addClass(btnClass);
buttonContainer.text(' ' + this.__localize(btnText)).addClass('btn-default btn-secondary btn-sm').addClass(btnClass);
if (btnClass.match(/btn\-(primary|success|info|warning|danger|link)/)) {
buttonContainer.removeClass('btn-default');
buttonContainer.removeClass('btn-default btn-secondary');
}
buttonContainer.attr({
'type': 'button',
Expand Down Expand Up @@ -973,7 +973,7 @@
width: 'inherit',
height: 'inherit',
resize: 'none',
iconlibrary: 'glyph',
iconlibrary: 'fa',
language: 'en',
initialstate: 'editor',
parser: null,
Expand All @@ -989,7 +989,6 @@
hotkey: 'Ctrl+B',
title: 'Bold',
icon: {
glyph: 'glyphicon glyphicon-bold',
fa: 'fa fa-bold',
'fa-3': 'icon-bold',
octicons: 'octicon octicon-bold'
Expand Down Expand Up @@ -1025,7 +1024,6 @@
title: 'Italic',
hotkey: 'Ctrl+I',
icon: {
glyph: 'glyphicon glyphicon-italic',
fa: 'fa fa-italic',
'fa-3': 'icon-italic',
octicons: 'octicon octicon-italic'
Expand Down Expand Up @@ -1061,7 +1059,6 @@
title: 'Heading',
hotkey: 'Ctrl+H',
icon: {
glyph: 'glyphicon glyphicon-header',
fa: 'fa fa-header',
'fa-3': 'icon-font',
octicons: 'octicon octicon-text-size'
Expand Down Expand Up @@ -1105,7 +1102,6 @@
title: 'URL/Link',
hotkey: 'Ctrl+L',
icon: {
glyph: 'glyphicon glyphicon-link',
fa: 'fa fa-link',
'fa-3': 'icon-link',
octicons: 'octicon octicon-link'
Expand Down Expand Up @@ -1142,7 +1138,6 @@
title: 'Image',
hotkey: 'Ctrl+G',
icon: {
glyph: 'glyphicon glyphicon-picture',
fa: 'fa fa-picture-o',
'fa-3': 'icon-picture',
octicons: 'octicon octicon-file-media'
Expand Down Expand Up @@ -1185,7 +1180,6 @@
hotkey: 'Ctrl+U',
title: 'Unordered List',
icon: {
glyph: 'glyphicon glyphicon-list',
fa: 'fa fa-list',
'fa-3': 'icon-list-ul',
octicons: 'octicon octicon-list-unordered'
Expand Down Expand Up @@ -1236,7 +1230,6 @@
hotkey: 'Ctrl+O',
title: 'Ordered List',
icon: {
glyph: 'glyphicon glyphicon-th-list',
fa: 'fa fa-list-ol',
'fa-3': 'icon-list-ol',
octicons: 'octicon octicon-list-ordered'
Expand Down Expand Up @@ -1289,7 +1282,6 @@
hotkey: 'Ctrl+K',
title: 'Code',
icon: {
glyph: 'glyphicon glyphicon-console',
fa: 'fa fa-code',
'fa-3': 'icon-code',
octicons: 'octicon octicon-code'
Expand Down Expand Up @@ -1333,7 +1325,6 @@
hotkey: 'Ctrl+Q',
title: 'Quote',
icon: {
glyph: 'glyphicon glyphicon-comment',
fa: 'fa fa-quote-left',
'fa-3': 'icon-quote-left',
octicons: 'octicon octicon-quote'
Expand Down Expand Up @@ -1391,7 +1382,6 @@
btnText: 'Preview',
btnClass: 'btn btn-primary btn-sm',
icon: {
glyph: 'glyphicon glyphicon-search',
fa: 'fa fa-search',
'fa-3': 'icon-search',
octicons: 'octicon octicon-search'
Expand Down Expand Up @@ -1424,7 +1414,6 @@
name: "fullscreenOn",
icon: {
fa: 'fa fa-expand',
glyph: 'glyphicon glyphicon-fullscreen',
'fa-3': 'icon-resize-full',
octicons: 'octicon octicon-link-external'
}
Expand All @@ -1433,7 +1422,6 @@
name: "fullscreenOff",
icon: {
fa: 'fa fa-compress',
glyph: 'glyphicon glyphicon-fullscreen',
'fa-3': 'icon-resize-small',
octicons: 'octicon octicon-browser'
}
Expand Down