mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-05 09:41:40 +09:00
95 lines
3.8 KiB
HTML
Executable file
95 lines
3.8 KiB
HTML
Executable file
<!-- css -->
|
|
<load target="css/default.css" />
|
|
<load target="../../../../common/xeicon/xeicon.min.css" />
|
|
|
|
<!-- JS -->
|
|
<!--%load_js_plugin("ckeditor")-->
|
|
<load target="../../tpl/js/editor_common.js" />
|
|
<load target="../../tpl/js/editor.app.js" />
|
|
<load target="js/xe_interface.js" />
|
|
|
|
<script>
|
|
var auto_saved_msg = "{$lang->msg_auto_saved}";
|
|
</script>
|
|
|
|
{@ $css_content = null }
|
|
<!--@if($content_font || $content_font_size)-->
|
|
{@ $css_content .= ' .xe_content.editable { '}
|
|
<block cond="$content_font">{@ $css_content .= 'font-family:' . $content_font . ';';}</block>
|
|
<block cond="$content_font_size">{@ $css_content .= 'font-size:' . $content_font_size . ';';}</block>
|
|
<block cond="$content_line_height">{@ $css_content .= 'line-height:' . $content_line_height . ';';}</block>
|
|
<block cond="$content_word_break === 'none'">{@ $css_content .= 'white-space: nowrap;';}</block>
|
|
<block cond="$content_word_break !== 'none'">{@ $css_content .= 'word-break:' . ($content_word_break ?: 'normal') . '; word-wrap: break-word;';}</block>
|
|
{@ $css_content .= chr(125);}
|
|
<block cond="$content_paragraph_spacing">{@ $css_content .= '.xe_content.editable p { margin: 0 0 ' . $content_paragraph_spacing . ' 0;' . chr(125);}</block>
|
|
<!--@endif-->
|
|
|
|
<!--@if($enable_autosave)-->
|
|
<input type="hidden" name="_saved_doc_title" value="{htmlspecialchars($saved_doc->title, ENT_COMPAT | ENT_HTML401, 'UTF-8', false)}" />
|
|
<input type="hidden" name="_saved_doc_content" value="{htmlspecialchars($saved_doc->content, ENT_COMPAT | ENT_HTML401, 'UTF-8', false)}" />
|
|
<input type="hidden" name="_saved_doc_document_srl" value="{$saved_doc->document_srl}" />
|
|
<input type="hidden" name="_saved_doc_message" value="{$lang->msg_load_saved_doc}" />
|
|
<!--@end-->
|
|
|
|
<div id="ckeditor_instance_{$editor_sequence}" data-editor-sequence="{$editor_sequence}" data-editor-primary-key-name="{$editor_primary_key_name}" data-editor-content-key-name="{$editor_content_key_name}" style="min-height:{$editor_height}px;"></div>
|
|
|
|
<p cond="$enable_autosave" class="editor_autosaved_message autosave_message" id="editor_autosaved_message_{$editor_sequence}"> </p>
|
|
|
|
<block cond="$allow_fileupload">
|
|
<include target="file_upload.html" />
|
|
</block>
|
|
|
|
<script>
|
|
(function($){
|
|
"use strict";
|
|
// editor
|
|
$(function(){
|
|
<!--@if(!FileHandler::exists('common/js/plugins/ckeditor/ckeditor/config.js'))-->CKEDITOR.config.customConfig = '';<!--@endif-->
|
|
var settings = {
|
|
ckeconfig: {
|
|
height: '{$editor_height}',
|
|
skin: '{$colorset}',
|
|
contentsCss: '{$content_style_path}/editor.css?{date("YmdHis", @filemtime($content_style_path."/editor.css"))}',
|
|
xe_editor_sequence: {$editor_sequence},
|
|
toolbarCanCollapse: true,
|
|
language: "{str_replace('jp','ja',$lang_type)}"
|
|
},
|
|
loadXeComponent: true,
|
|
enableToolbar: true,
|
|
content_field: jQuery('[name={$editor_content_key_name}]')
|
|
};
|
|
|
|
<!--@if($enable_component)-->
|
|
{@ $xe_component = array(); }
|
|
<!--@foreach($component_list as $component_name => $component)-->
|
|
{@ $xe_component[] = $component_name . ":'" . htmlentities($component->title, ENT_QUOTES, 'UTF-8') . "'"; }
|
|
<!--@endforeach-->
|
|
{@ $xe_component = implode(',', $xe_component); }
|
|
|
|
settings.ckeconfig.xe_component_arrays = {{$xe_component}};
|
|
<!--@endif-->
|
|
|
|
<!--@if(!$enable_default_component)-->
|
|
settings.enableToolbar = false;
|
|
settings.ckeconfig.toolbarCanCollapse = false;
|
|
<!--@endif-->
|
|
|
|
<!--@if(!$enable_component)-->
|
|
settings.loadXeComponent = false;
|
|
<!--@endif-->
|
|
|
|
<!--@if($module_type === 'comment'||Mobile::isMobileCheckByAgent())-->
|
|
settings.ckeconfig.toolbarStartupExpanded = false;
|
|
<!--@endif-->
|
|
|
|
<!--@if(!$html_mode)-->
|
|
settings.ckeconfig.removeButtons = 'Save,Preview,Print,Cut,Copy,Paste,Source';
|
|
<!--@endif-->
|
|
|
|
<!--@if($css_content)-->CKEDITOR.addCss('{$css_content}');<!--@end-->
|
|
|
|
var ckeApp = $('#ckeditor_instance_{$editor_sequence}').XeCkEditor(settings);
|
|
|
|
});
|
|
})(jQuery);
|
|
</script>
|