标记设置问题

发布于 2024-09-26 17:47:19 字数 1432 浏览 4 评论 0原文

这是我在 set.js 中的设置。我基本上不想要 H1 - H3 标签、图像等。所以我删除了这些行,但我的标记文本区域似乎不喜欢这些设置,并显示如下。我正在使用带有基本简单皮肤的纺织品套装。

另外,有没有图片的精灵版本?

替代文字

mySettings = {
    previewParserPath:  '', // path to your Textile parser
    onShiftEnter:       {keepDefault:false, replaceWith:'\n\n'},
    markupSet: [
        {name:'Heading 4', key:'4', openWith:'h4(!(([![Class]!]))!). ', placeHolder:'Your title here...' },
        {name:'Heading 5', key:'5', openWith:'h5(!(([![Class]!]))!). ', placeHolder:'Your title here...' },
        {name:'Heading 6', key:'6', openWith:'h6(!(([![Class]!]))!). ', placeHolder:'Your title here...' },
        {name:'Paragraph', key:'P', openWith:'p(!(([![Class]!]))!). '},
        {separator:'---------------' },
        {name:'Bold', key:'B', closeWith:'*', openWith:'*'},
        {name:'Italic', key:'I', closeWith:'_', openWith:'_'},
        {name:'Stroke through', key:'S', closeWith:'-', openWith:'-'},
        {separator:'---------------' },
        {name:'Bulleted list', openWith:'(!(* |!|*)!)'},
        {name:'Numeric list', openWith:'(!(# |!|#)!)'}, 
        {separator:'---------------' },
        {name:'Link', openWith:'"', closeWith:'([![Title]!])":[![Link:!:http://]!]', placeHolder:'Your text to link here...' },
        {separator:'---------------' },
        {name:'Quotes', openWith:'bq(!(([![Class]!]))!). '}
    ]
}

Here is my settings in set.js. I basically don't want the H1 - H3 tags, images etc. So I deleted those lines but my markitup text area appears to not like the settings and shows up like following. I am using the textile set with a basic simple skin.

Also, is there a sprited version of the images?

alt text

mySettings = {
    previewParserPath:  '', // path to your Textile parser
    onShiftEnter:       {keepDefault:false, replaceWith:'\n\n'},
    markupSet: [
        {name:'Heading 4', key:'4', openWith:'h4(!(([![Class]!]))!). ', placeHolder:'Your title here...' },
        {name:'Heading 5', key:'5', openWith:'h5(!(([![Class]!]))!). ', placeHolder:'Your title here...' },
        {name:'Heading 6', key:'6', openWith:'h6(!(([![Class]!]))!). ', placeHolder:'Your title here...' },
        {name:'Paragraph', key:'P', openWith:'p(!(([![Class]!]))!). '},
        {separator:'---------------' },
        {name:'Bold', key:'B', closeWith:'*', openWith:'*'},
        {name:'Italic', key:'I', closeWith:'_', openWith:'_'},
        {name:'Stroke through', key:'S', closeWith:'-', openWith:'-'},
        {separator:'---------------' },
        {name:'Bulleted list', openWith:'(!(* |!|*)!)'},
        {name:'Numeric list', openWith:'(!(# |!|#)!)'}, 
        {separator:'---------------' },
        {name:'Link', openWith:'"', closeWith:'([![Title]!])":[![Link:!:http://]!]', placeHolder:'Your text to link here...' },
        {separator:'---------------' },
        {name:'Quotes', openWith:'bq(!(([![Class]!]))!). '}
    ]
}

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

心是晴朗的。 2024-10-03 17:47:19

您实际上已经删除了按钮,只剩下图像背景。你也必须编辑CSS:(

/* -------------------------------------------------------------------
// markItUp!
// By Jay Salvat - http://markitup.jaysalvat.com/
// ------------------------------------------------------------------*/

}
.textile .markItUpButton1 a {
    background-image:url(images/h4.png); 
}
.textile .markItUpButton2 a {
    background-image:url(images/h5.png); 
}
.textile .markItUpButton3 a {
    background-image:url(images/h6.png); 
}
.textile .markItUpButton4 a {
    background-image:url(images/paragraph.png); 
}

.textile .markItUpButton5 a {
    background-image:url(images/bold.png);
}
.textile .markItUpButton6 a {
    background-image:url(images/italic.png);
}
.textile .markItUpButton7 a {
    background-image:url(images/stroke.png);
}

.textile .markItUpButton8 a {
    background-image:url(images/list-bullet.png);
}
.textile .markItUpButton9 a {
    background-image:url(images/list-numeric.png);
}

.textile .markItUpButton10 a {
    background-image:url(images/link.png);
}

.textile .markItUpButton11 a {
    background-image:url(images/quotes.png);
}

原始版本:http://markitup.jaysalvat.com/examples/textile / )

没有精灵版本 AFAIK,但你可以自己创建一个:-)

You have actually deleted the buttons, only image backgrounds remained. You have to edit css too:

/* -------------------------------------------------------------------
// markItUp!
// By Jay Salvat - http://markitup.jaysalvat.com/
// ------------------------------------------------------------------*/

}
.textile .markItUpButton1 a {
    background-image:url(images/h4.png); 
}
.textile .markItUpButton2 a {
    background-image:url(images/h5.png); 
}
.textile .markItUpButton3 a {
    background-image:url(images/h6.png); 
}
.textile .markItUpButton4 a {
    background-image:url(images/paragraph.png); 
}

.textile .markItUpButton5 a {
    background-image:url(images/bold.png);
}
.textile .markItUpButton6 a {
    background-image:url(images/italic.png);
}
.textile .markItUpButton7 a {
    background-image:url(images/stroke.png);
}

.textile .markItUpButton8 a {
    background-image:url(images/list-bullet.png);
}
.textile .markItUpButton9 a {
    background-image:url(images/list-numeric.png);
}

.textile .markItUpButton10 a {
    background-image:url(images/link.png);
}

.textile .markItUpButton11 a {
    background-image:url(images/quotes.png);
}

(original version: http://markitup.jaysalvat.com/examples/textile/ )

No sprited version AFAIK, but you can create one by yourself :-)

亢潮 2024-10-03 17:47:19

事实上,您只需要隐藏 CSS 文件中的按钮(使用 display: none;)。不要修改JS文件来评论或删除项目;您可以只评论或删除分隔符

 {separator:'---------------' },

In fact, you just need to hide buttons in the CSS file (using display: none;). Don't modify the JS file to comment or remove items; you can just comment or remove separators

 {separator:'---------------' },
嗳卜坏 2024-10-03 17:47:19

如果你想隐藏一些按钮,你应该改变的是CSS文件而不是JS设置文件。

.markItUp .markItUpButton1 a {
background-image:url(images/h1.png); 
display: none;}

只要设置显示:无就可以了。

If you want to hide some buttons, what you should change is the CSS file but not the JS settings file.

.markItUp .markItUpButton1 a {
background-image:url(images/h1.png); 
display: none;}

Just set display: none is ok.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文