feat: formatiertes Einfügen aus Word unterstützen
This commit is contained in:
@@ -5,7 +5,7 @@ class DocumentationConfig(PluginConfig):
|
||||
name = "netbox_documentation"
|
||||
verbose_name = "Dokumentation"
|
||||
description = "Wiki und Office-Dokumentation direkt in NetBox"
|
||||
version = "0.3.1"
|
||||
version = "0.3.2"
|
||||
author = "NetBox Documentation Contributors"
|
||||
base_url = "documentation"
|
||||
min_version = "4.0.0"
|
||||
|
||||
@@ -52,7 +52,10 @@ class Document(NetBoxModel):
|
||||
css = CSSSanitizer(allowed_css_properties={
|
||||
"background-color", "border", "border-color", "border-style", "border-width",
|
||||
"color", "font-family", "font-size", "font-style", "font-weight", "height",
|
||||
"margin-left", "text-align", "text-decoration", "vertical-align", "width",
|
||||
"border-collapse", "line-height", "list-style-type", "margin", "margin-bottom",
|
||||
"margin-left", "margin-right", "margin-top", "padding", "padding-bottom",
|
||||
"padding-left", "padding-right", "padding-top", "text-align", "text-decoration",
|
||||
"text-indent", "vertical-align", "white-space", "width",
|
||||
})
|
||||
return bleach.clean(value, tags=tags, attributes=attributes, protocols=("http", "https", "mailto"), css_sanitizer=css)
|
||||
|
||||
|
||||
@@ -48,6 +48,13 @@
|
||||
promotion: false,
|
||||
branding: false,
|
||||
convert_unsafe_embeds: true,
|
||||
paste_data_images: true,
|
||||
paste_merge_formats: false,
|
||||
paste_webkit_styles: 'all',
|
||||
paste_remove_styles_if_webkit: false,
|
||||
paste_convert_word_fake_lists: true,
|
||||
smart_paste: true,
|
||||
images_reuse_filename: true,
|
||||
relative_urls: false
|
||||
{% if object.pk %},
|
||||
images_file_types: 'jpg,jpeg,png,gif,webp',
|
||||
|
||||
Reference in New Issue
Block a user