parent
cb21952155
commit
4af19dd646
@ -0,0 +1,14 @@
|
||||
[#ftl]
|
||||
[#-- @implicitly included --]
|
||||
[#-- @ftlvariable name="imgurls" type="String" --]
|
||||
[#-- @ftlvariable name="watermarkAngle" type="String" --]
|
||||
[#-- @ftlvariable name="watermarkHeight" type="String" --]
|
||||
[#-- @ftlvariable name="watermarkWidth" type="String" --]
|
||||
[#-- @ftlvariable name="watermarkAlpha" type="String" --]
|
||||
[#-- @ftlvariable name="watermarkColor" type="String" --]
|
||||
[#-- @ftlvariable name="watermarkFontsize" type="String" --]
|
||||
[#-- @ftlvariable name="watermarkFont" type="String" --]
|
||||
[#-- @ftlvariable name="watermarkYSpace" type="String" --]
|
||||
[#-- @ftlvariable name="watermarkXSpace" type="String" --]
|
||||
[#-- @ftlvariable name="watermarkTxt" type="String" --]
|
||||
[#-- @ftlvariable name="ordinaryUrl" type="String" --]
|
@ -0,0 +1,27 @@
|
||||
package cn.keking.service.impl;
|
||||
|
||||
import cn.keking.model.FileAttribute;
|
||||
import cn.keking.service.FilePreview;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.ui.Model;
|
||||
|
||||
/**
|
||||
* @author kl (http://kailing.pub)
|
||||
* @since 2020/12/25
|
||||
*/
|
||||
@Service
|
||||
public class MarkdownFilePreviewImpl implements FilePreview {
|
||||
|
||||
private final SimTextFilePreviewImpl simTextFilePreview;
|
||||
|
||||
public MarkdownFilePreviewImpl(SimTextFilePreviewImpl simTextFilePreview) {
|
||||
this.simTextFilePreview = simTextFilePreview;
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public String filePreviewHandle(String url, Model model, FileAttribute fileAttribute) {
|
||||
model.addAttribute("markdown","true");
|
||||
return simTextFilePreview.filePreviewHandle(url, model, fileAttribute);
|
||||
}
|
||||
}
|
File diff suppressed because one or more lines are too long
Loading…
Reference in new issue