mirror of
https://github.com/kekingcn/kkFileView.git
synced 2026-03-31 14:29:53 +00:00
Compare commits
1 Commits
klboke-pat
...
xmind
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
4a7d61a335 |
17
README.cn.md
17
README.cn.md
@@ -1,16 +1,14 @@
|
||||
# kkFileView
|
||||
文档在线预览项目解决方案,项目使用流行的spring boot搭建,易上手和部署。万能的文件预览开源项目,基本支持主流文档格式预览,如:
|
||||
1. 支持 doc, docx, xls, xlsx, xlsm, ppt, pptx, csv, tsv, dotm, xlt, xltm, dot, dotx,xlam, xla 等 Office 办公文档
|
||||
2. 支持 wps, dps, et, ett, wpt 等国产 WPS Office 办公文档
|
||||
1. 支持 doc, docx, xls, xlsx, xlsm, ppt, pptx, csv, tsv 等 Office 办公文档
|
||||
2. 支持 wps, dps, et 等国产 WPS Office 办公文档
|
||||
3. 支持 odt, ods, ots, odp, otp, six, ott, fodt, fods 等OpenOffice、LibreOffice 办公文档
|
||||
4. 支持 vsd, vsdx 等 Visio 流程图文件
|
||||
5. 支持 wmf, emf 等 Windows 系统图像文件
|
||||
6. 支持 psd 等 Photoshop 软件模型文件
|
||||
7. 支持 pdf ,ofd, rtf 等文档
|
||||
8. 支持 xmind 软件模型文件
|
||||
9. 支持 bpmn 工作流文件
|
||||
9. 支持 eml 邮件文件
|
||||
10. 支持 epub 图书文档
|
||||
9. 支持 eml, epub 文档类型文件
|
||||
10. 支持 obj, 3ds, stl, ply, gltf, glb, off, 3dm, fbx, dae, wrl, 3mf, ifc, brep, step, iges, fcstd, bim 等 3D 模型文件
|
||||
11. 支持 dwg, dxf 等 CAD 模型文件
|
||||
12. 支持 txt, xml(渲染), md(渲染), java, php, py, js, css 等所有纯文本
|
||||
@@ -19,8 +17,7 @@
|
||||
15. 支持 tif, tiff 图信息模型文件
|
||||
16. 支持 tga 图像格式文件
|
||||
17. 支持 svg 矢量图像格式文件
|
||||
18. 支持 mp3,wav,mp4,flv 等音视频格式文件
|
||||
19. 支持 avi,mov,rm,webm,ts,rm,mkv,mpeg,ogg,mpg,rmvb,wmv,3gp,ts,swf 等视频格式转码预览
|
||||
18. 支持 avi, mov, wmv, mkv, 3gp, rm 等众多音视频格式文件
|
||||
|
||||
> 基于当前良好的架构模式,支持的文件类型在进一步丰富中
|
||||
### 项目特性
|
||||
@@ -37,7 +34,7 @@
|
||||
### 在线体验
|
||||
> 请善待公共服务,会不定时停用
|
||||
|
||||
地址:[https://file.kkview.cn](https://file.kkview.cn)
|
||||
地址:[https://kkview.cn/preview/index](https://kkview.cn/preview/index)
|
||||
|
||||
### 项目文档(Project documentation)
|
||||
1. 详细wiki文档:https://gitee.com/kekingcn/file-online-preview/wikis/pages
|
||||
@@ -47,7 +44,7 @@
|
||||
### 联系我们,加入组织
|
||||
> 我们会用心回答解决大家在项目使用中的问题,也请大家在提问前至少 Google 或 baidu 过,珍爱生命远离无效的交流沟通
|
||||
|
||||

|
||||

|
||||
|
||||
|
||||
### 文档预览效果
|
||||
@@ -278,7 +275,7 @@ epub 引用于 [ epub.js](https://github.com/futurepress/epub.js) 开源协议
|
||||
[](https://starchart.cc/kekingcn/kkFileView)
|
||||
|
||||
### 鸣谢
|
||||
- 本项目诞生于[凯京集团],在取得公司高层同意后以 Apache 协议开源出来反哺社区,在此特别感谢凯京集团,以及集团领导[@唐老大](https://github.com/tangshd)的支持、@端木详笑的贡献。
|
||||
- 本项目诞生于[凯京集团],在取得公司高层同意后以 Apache 协议开源出来反哺社区,在此特别感谢凯京集团,以及集团领导@唐老大的支持、@端木详笑的贡献。
|
||||
- 本项目已脱离公司由[KK开源社区]维护发展壮大,感谢所有给 kkFileView 提 Issue 、Pr 开发者
|
||||
- 本项目引入的第三方组件已在 '关于引用' 列表列出,感谢这些项目,让 kkFileView 更出色
|
||||
|
||||
|
||||
17
README.md
17
README.md
@@ -4,17 +4,15 @@
|
||||
|
||||
Document online preview project solution, built using the popular Spring Boot framework for easy setup and deployment. This versatile open source project provides basic support for a wide range of document formats, including:
|
||||
|
||||
1. Supports Office documents such as `doc`, `docx`, `xls`, `xlsx`, `xlsm`, `ppt`, `pptx`, `csv`, `tsv`, , `dotm`, `xlt`, `xltm`, `dot`, `xlam`, `dotx`, `xla,` etc.
|
||||
2. Supports domestic WPS Office documents such as `wps`, `dps`, `et` , `ett`, ` wpt`.
|
||||
1. Supports Office documents such as `doc`, `docx`, `xls`, `xlsx`, `xlsm`, `ppt`, `pptx`, `csv`, `tsv`, etc.
|
||||
2. Supports domestic WPS Office documents such as `wps`, `dps`, et.
|
||||
3. Supports OpenOffice, LibreOffice office documents such as `odt`, `ods`, `ots`, `odp`, `otp`, `six`, `ott`, `fodt` and `fods`.
|
||||
4. Supports Visio flowchart files such as `vsd`, `vsdx`.
|
||||
5. Supports Windows system image files such as `wmf`, `emf`.
|
||||
6. Supports Photoshop software model files such as `psd`.
|
||||
7. Supports document formats like `pdf`, `ofd`, and `rtf`.
|
||||
8. Supports software model files like `xmind`.
|
||||
9. Support for `bpmn` workflow files.
|
||||
9. Support for `eml` mail files
|
||||
10. Support for `epub` book documents
|
||||
8. Supports software model files like `xmind`.
|
||||
9. Supports document type files such as `eml`, `epub`.
|
||||
10. Supports 3D model files like `obj`, `3ds`, `stl`, `ply`, `gltf`, `glb`, `off`, `3dm`, `fbx`, `dae`, `wrl`, `3mf`, `ifc`, `brep`, `step`, `iges`, `fcstd`, `bim`, etc.
|
||||
11. Supports CAD model files such as `dwg`, `dxf`.
|
||||
12. Supports all plain text files such as `txt`, `xml` (rendering), `md` (rendering), `java`, `php`, `py`, `js`, `css`, etc.
|
||||
@@ -39,12 +37,7 @@ URL:[https://kkview.cn](https://kkview.cn/)
|
||||
### Live demo
|
||||
> Please treat public service kindly, or this would stop at any time.
|
||||
|
||||
URL:[https://file.kkview.cn](https://file.kkview.cn)
|
||||
|
||||
### Contact Us
|
||||
> We will answer your questions carefully and solve any problems you encounter while using the project. We also kindly ask that you at least Google or Baidu before asking questions in order to save time and avoid ineffective communication. Let's cherish our lives and stay away from ineffective communication.
|
||||
|
||||
<img src="./doc/github星球.png/" width="50%">
|
||||
URL:[https://kkview.cn/preview/index](https://kkview.cn/preview/index)
|
||||
|
||||
### Quick Start
|
||||
> Technology stack
|
||||
|
||||
BIN
doc/gitee星球.png
BIN
doc/gitee星球.png
Binary file not shown.
|
Before Width: | Height: | Size: 92 KiB |
BIN
doc/github星球.png
BIN
doc/github星球.png
Binary file not shown.
|
Before Width: | Height: | Size: 148 KiB |
BIN
doc/知识星球.png
Normal file
BIN
doc/知识星球.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 30 KiB |
8
pom.xml
8
pom.xml
@@ -11,19 +11,19 @@
|
||||
<properties>
|
||||
<java.version>1.8</java.version>
|
||||
|
||||
<jodconverter.version>4.4.6</jodconverter.version>
|
||||
<jodconverter.version>4.4.5</jodconverter.version>
|
||||
<spring.boot.version>2.4.2</spring.boot.version>
|
||||
<poi.version>5.2.2</poi.version>
|
||||
<xdocreport.version>1.0.6</xdocreport.version>
|
||||
<xstream.version>1.4.20</xstream.version>
|
||||
<junrar.version>7.5.4</junrar.version>
|
||||
<xstream.version>1.4.19</xstream.version>
|
||||
<junrar.version>7.4.1</junrar.version>
|
||||
<redisson.version>3.2.0</redisson.version>
|
||||
<sevenzipjbinding.version>16.02-2.01</sevenzipjbinding.version>
|
||||
<jchardet.version>1.0</jchardet.version>
|
||||
<antlr.version>2.7.7</antlr.version>
|
||||
<concurrentlinkedhashmap.version>1.4.2</concurrentlinkedhashmap.version>
|
||||
<rocksdb.version>5.17.2</rocksdb.version>
|
||||
<pdfbox.version>2.0.27</pdfbox.version>
|
||||
<pdfbox.version>2.0.26</pdfbox.version>
|
||||
<jai-imageio.version>1.4.0</jai-imageio.version>
|
||||
<jbig2-imageio.version>3.0.4</jbig2-imageio.version>
|
||||
<galimatias.version>0.2.1</galimatias.version>
|
||||
|
||||
@@ -43,7 +43,6 @@ public class WebConfig implements WebMvcConfigurer {
|
||||
Set<String> filterUri = new HashSet<>();
|
||||
filterUri.add("/onlinePreview");
|
||||
filterUri.add("/picturesPreview");
|
||||
filterUri.add("/getCorsFile");
|
||||
TrustHostFilter filter = new TrustHostFilter();
|
||||
FilterRegistrationBean<TrustHostFilter> registrationBean = new FilterRegistrationBean<>();
|
||||
registrationBean.setFilter(filter);
|
||||
@@ -68,7 +67,6 @@ public class WebConfig implements WebMvcConfigurer {
|
||||
public FilterRegistrationBean<BaseUrlFilter> getBaseUrlFilter() {
|
||||
Set<String> filterUri = new HashSet<>();
|
||||
filterUri.add("/index");
|
||||
filterUri.add("/");
|
||||
filterUri.add("/onlinePreview");
|
||||
filterUri.add("/picturesPreview");
|
||||
BaseUrlFilter filter = new BaseUrlFilter();
|
||||
@@ -82,7 +80,6 @@ public class WebConfig implements WebMvcConfigurer {
|
||||
public FilterRegistrationBean<AttributeSetFilter> getWatermarkConfigFilter() {
|
||||
Set<String> filterUri = new HashSet<>();
|
||||
filterUri.add("/index");
|
||||
filterUri.add("/");
|
||||
filterUri.add("/onlinePreview");
|
||||
filterUri.add("/picturesPreview");
|
||||
AttributeSetFilter filter = new AttributeSetFilter();
|
||||
|
||||
@@ -29,10 +29,9 @@ public enum FileType {
|
||||
Online3D("online3DFilePreviewImpl"),
|
||||
XMIND("xmindFilePreviewImpl"),
|
||||
SVG("svgFilePreviewImpl"),
|
||||
Epub("epubFilePreviewImpl"),
|
||||
BPMN("bpmnFilePreviewImpl");
|
||||
Epub("epubFilePreviewImpl");
|
||||
|
||||
private static final String[] OFFICE_TYPES = {"docx", "wps", "doc", "docm", "xls", "xlsx", "csv" ,"xlsm", "ppt", "pptx", "vsd", "rtf", "odt", "wmf", "emf", "dps", "et", "ods", "ots", "tsv", "odp", "otp", "sxi", "ott", "vsdx", "fodt", "fods", "xltx","tga","psd","dotm","ett","xlt","xltm","wpt","dot","xlam","dotx","xla"};
|
||||
private static final String[] OFFICE_TYPES = {"docx", "wps", "doc", "docm", "xls", "xlsx", "csv" ,"xlsm", "ppt", "pptx", "vsd", "rtf", "odt", "wmf", "emf", "dps", "et", "ods", "ots", "tsv", "odp", "otp", "sxi", "ott", "vsdx", "fodt", "fods", "xltx","tga","psd"};
|
||||
private static final String[] PICTURE_TYPES = {"jpg", "jpeg", "png", "gif", "bmp", "ico", "jfif", "webp"};
|
||||
private static final String[] ARCHIVE_TYPES = {"rar", "zip", "jar", "7-zip", "tar", "gzip", "7z"};
|
||||
private static final String[] Online3D_TYPES = {"obj", "3ds", "stl", "ply", "off", "3dm", "fbx", "dae", "wrl", "3mf", "ifc","glb","o3dv","gltf","stp","bim","fcstd","step","iges","brep"};
|
||||
@@ -99,7 +98,6 @@ public enum FileType {
|
||||
FILE_TYPE_MAPPER.put("xml", FileType.XML);
|
||||
FILE_TYPE_MAPPER.put("pdf", FileType.PDF);
|
||||
FILE_TYPE_MAPPER.put("flv", FileType.FLV);
|
||||
FILE_TYPE_MAPPER.put("bpmn", FileType.BPMN);
|
||||
}
|
||||
|
||||
private static FileType to(String fileType) {
|
||||
|
||||
@@ -4,14 +4,13 @@ import cn.keking.config.ConfigConstants;
|
||||
import cn.keking.model.FileAttribute;
|
||||
import cn.keking.model.FileType;
|
||||
import cn.keking.service.cache.CacheService;
|
||||
import cn.keking.service.cache.NotResourceCache;
|
||||
import cn.keking.utils.EncodingDetects;
|
||||
import cn.keking.utils.KkFileUtils;
|
||||
import cn.keking.utils.WebUtils;
|
||||
import com.aspose.cad.CodePages;
|
||||
import com.aspose.cad.Color;
|
||||
import com.aspose.cad.Image;
|
||||
import com.aspose.cad.LoadOptions;
|
||||
import com.aspose.cad.fileformats.cad.CadDrawTypeMode;
|
||||
import com.aspose.cad.imageoptions.CadRasterizationOptions;
|
||||
import com.aspose.cad.imageoptions.PdfOptions;
|
||||
import org.apache.pdfbox.pdmodel.PDDocument;
|
||||
@@ -41,6 +40,8 @@ import java.util.Map;
|
||||
public class FileHandlerService {
|
||||
|
||||
private final Logger logger = LoggerFactory.getLogger(FileHandlerService.class);
|
||||
|
||||
private static final String DEFAULT_CONVERTER_CHARSET = System.getProperty("sun.jnu.encoding");
|
||||
private final String fileDir = ConfigConstants.getFileDir();
|
||||
private final CacheService cacheService;
|
||||
|
||||
@@ -140,10 +141,9 @@ public class FileHandlerService {
|
||||
* @param outFilePath 文件绝对路径
|
||||
*/
|
||||
public void doActionConvertedFile(String outFilePath) {
|
||||
String charset = EncodingDetects.getJavaEncode(outFilePath);
|
||||
StringBuilder sb = new StringBuilder();
|
||||
try (InputStream inputStream = new FileInputStream(outFilePath);
|
||||
BufferedReader reader = new BufferedReader(new InputStreamReader(inputStream, charset))) {
|
||||
BufferedReader reader = new BufferedReader(new InputStreamReader(inputStream, DEFAULT_CONVERTER_CHARSET))) {
|
||||
String line;
|
||||
while (null != (line = reader.readLine())) {
|
||||
if (line.contains("charset=gb2312")) {
|
||||
@@ -198,7 +198,6 @@ public class FileHandlerService {
|
||||
return null;
|
||||
}
|
||||
PDDocument doc = PDDocument.load(pdfFile);
|
||||
doc.setResourceCache(new NotResourceCache());
|
||||
int pageCount = doc.getNumberOfPages();
|
||||
PDFRenderer pdfRenderer = new PDFRenderer(doc);
|
||||
|
||||
@@ -286,7 +285,7 @@ public class FileHandlerService {
|
||||
attribute.setSkipDownLoad(true);
|
||||
}
|
||||
url = WebUtils.encodeUrlFileName(url);
|
||||
fileName = KkFileUtils.htmlEscape(fileName); //文件名处理
|
||||
fileName = KkFileUtils.htmlEscape(fileName); //文件名处理
|
||||
attribute.setType(type);
|
||||
attribute.setName(fileName);
|
||||
attribute.setSuffix(suffix);
|
||||
|
||||
@@ -28,7 +28,6 @@ public interface FilePreview {
|
||||
String EXEL_FILE_PREVIEW_PAGE = "html";
|
||||
String XML_FILE_PREVIEW_PAGE = "xml";
|
||||
String MARKDOWN_FILE_PREVIEW_PAGE = "markdown";
|
||||
String BPMN_FILE_PREVIEW_PAGE = "bpmn";
|
||||
String NOT_SUPPORTED_FILE_PAGE = "fileNotSupported";
|
||||
|
||||
String filePreviewHandle(String url, Model model, FileAttribute fileAttribute);
|
||||
|
||||
@@ -1,20 +0,0 @@
|
||||
package cn.keking.service.cache;
|
||||
|
||||
import org.apache.pdfbox.cos.COSObject;
|
||||
import org.apache.pdfbox.pdmodel.DefaultResourceCache;
|
||||
import org.apache.pdfbox.pdmodel.graphics.PDXObject;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
/**
|
||||
* @author: Sawyer.Yong
|
||||
* @since: 2023/02/18 14:45
|
||||
* 解决图片 SoftReference 导致内存无法被回收导致的OOM, 详见 https://issues.apache.org/jira/browse/PDFBOX-3700
|
||||
*/
|
||||
public class NotResourceCache extends DefaultResourceCache {
|
||||
|
||||
@Override
|
||||
public void put(COSObject indirect, PDXObject xobject) throws IOException {
|
||||
// do nothing
|
||||
}
|
||||
}
|
||||
@@ -1,27 +0,0 @@
|
||||
package cn.keking.service.impl;
|
||||
|
||||
import cn.keking.model.FileAttribute;
|
||||
import cn.keking.service.FilePreview;
|
||||
import org.springframework.stereotype.Component;
|
||||
import org.springframework.ui.Model;
|
||||
|
||||
/**
|
||||
* @author kl (http://kailing.pub)
|
||||
* @since 2023/3/9
|
||||
*/
|
||||
@Component
|
||||
public class BpmnFilePreviewImpl implements FilePreview {
|
||||
|
||||
private final CommonPreviewImpl commonPreview;
|
||||
|
||||
public BpmnFilePreviewImpl(CommonPreviewImpl commonPreview) {
|
||||
this.commonPreview = commonPreview;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String filePreviewHandle(String url, Model model, FileAttribute fileAttribute) {
|
||||
commonPreview.filePreviewHandle(url,model,fileAttribute);
|
||||
model.addAttribute("fileName", fileAttribute.getName());
|
||||
return FilePreview.BPMN_FILE_PREVIEW_PAGE;
|
||||
}
|
||||
}
|
||||
@@ -1,48 +0,0 @@
|
||||
package cn.keking.service.impl;
|
||||
|
||||
import cn.keking.model.FileAttribute;
|
||||
import cn.keking.model.ReturnResponse;
|
||||
import cn.keking.service.FileHandlerService;
|
||||
import cn.keking.service.FilePreview;
|
||||
import cn.keking.utils.DownloadUtils;
|
||||
import cn.keking.utils.KkFileUtils;
|
||||
import org.springframework.stereotype.Component;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.ui.Model;
|
||||
import org.springframework.util.CollectionUtils;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Created by kl on 2018/1/17.
|
||||
* Content :图片文件处理
|
||||
*/
|
||||
@Component("commonPreview")
|
||||
public class CommonPreviewImpl implements FilePreview {
|
||||
|
||||
private final FileHandlerService fileHandlerService;
|
||||
private final OtherFilePreviewImpl otherFilePreview;
|
||||
|
||||
public CommonPreviewImpl(FileHandlerService fileHandlerService, OtherFilePreviewImpl otherFilePreview) {
|
||||
this.fileHandlerService = fileHandlerService;
|
||||
this.otherFilePreview = otherFilePreview;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String filePreviewHandle(String url, Model model, FileAttribute fileAttribute) {
|
||||
// 不是http开头,浏览器不能直接访问,需下载到本地
|
||||
if (url != null && !url.toLowerCase().startsWith("http")) {
|
||||
ReturnResponse<String> response = DownloadUtils.downLoad(fileAttribute, null);
|
||||
if (response.isFailure()) {
|
||||
return otherFilePreview.notSupportedFile(model, fileAttribute, response.getMsg());
|
||||
} else {
|
||||
String file = fileHandlerService.getRelativePath(response.getContent());
|
||||
model.addAttribute("currentUrl", file);
|
||||
}
|
||||
} else {
|
||||
model.addAttribute("currentUrl", url);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
@@ -11,15 +11,15 @@ import org.springframework.ui.Model;
|
||||
@Service
|
||||
public class EmlFilePreviewImpl implements FilePreview {
|
||||
|
||||
private final CommonPreviewImpl commonPreview;
|
||||
private final PictureFilePreviewImpl pictureFilePreview;
|
||||
|
||||
public EmlFilePreviewImpl(CommonPreviewImpl commonPreview) {
|
||||
this.commonPreview = commonPreview;
|
||||
public EmlFilePreviewImpl(PictureFilePreviewImpl pictureFilePreview) {
|
||||
this.pictureFilePreview = pictureFilePreview;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String filePreviewHandle(String url, Model model, FileAttribute fileAttribute) {
|
||||
commonPreview.filePreviewHandle(url,model,fileAttribute);
|
||||
pictureFilePreview.filePreviewHandle(url,model,fileAttribute);
|
||||
return EML_FILE_PREVIEW_PAGE;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,15 +13,15 @@ import org.springframework.ui.Model;
|
||||
@Service
|
||||
public class EpubFilePreviewImpl implements FilePreview {
|
||||
|
||||
private final CommonPreviewImpl commonPreview;
|
||||
private final PictureFilePreviewImpl pictureFilePreview;
|
||||
|
||||
public EpubFilePreviewImpl(CommonPreviewImpl commonPreview) {
|
||||
this.commonPreview = commonPreview;
|
||||
public EpubFilePreviewImpl(PictureFilePreviewImpl pictureFilePreview) {
|
||||
this.pictureFilePreview = pictureFilePreview;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String filePreviewHandle(String url, Model model, FileAttribute fileAttribute) {
|
||||
commonPreview.filePreviewHandle(url,model,fileAttribute);
|
||||
pictureFilePreview.filePreviewHandle(url,model,fileAttribute);
|
||||
return EpubFilePreviewImpl;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,15 +13,15 @@ import org.springframework.ui.Model;
|
||||
@Service
|
||||
public class OfdFilePreviewImpl implements FilePreview {
|
||||
|
||||
private final CommonPreviewImpl commonPreview;
|
||||
private final PictureFilePreviewImpl pictureFilePreview;
|
||||
|
||||
public OfdFilePreviewImpl(CommonPreviewImpl commonPreview) {
|
||||
this.commonPreview = commonPreview;
|
||||
public OfdFilePreviewImpl(PictureFilePreviewImpl pictureFilePreview) {
|
||||
this.pictureFilePreview = pictureFilePreview;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String filePreviewHandle(String url, Model model, FileAttribute fileAttribute) {
|
||||
commonPreview.filePreviewHandle(url,model,fileAttribute);
|
||||
pictureFilePreview.filePreviewHandle(url,model,fileAttribute);
|
||||
return OFD_FILE_PREVIEW_PAGE;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -47,7 +47,7 @@ public class OfficeFilePreviewImpl implements FilePreview {
|
||||
String fileName = fileAttribute.getName();
|
||||
String filePassword = fileAttribute.getFilePassword();
|
||||
String userToken = fileAttribute.getUserToken();
|
||||
boolean isHtml = suffix.equalsIgnoreCase("xls") || suffix.equalsIgnoreCase("xlsx") || suffix.equalsIgnoreCase("csv") || suffix.equalsIgnoreCase("xlsm") || suffix.equalsIgnoreCase("xlt") || suffix.equalsIgnoreCase("xltm") || suffix.equalsIgnoreCase("et") || suffix.equalsIgnoreCase("ett") || suffix.equalsIgnoreCase("xlam");
|
||||
boolean isHtml = suffix.equalsIgnoreCase("xls") || suffix.equalsIgnoreCase("xlsx") || suffix.equalsIgnoreCase("csv");
|
||||
String pdfName = fileName.substring(0, fileName.lastIndexOf(".") + 1) + (isHtml ? "html" : "pdf");
|
||||
String cacheFileName = userToken == null ? pdfName : userToken + "_" + pdfName;
|
||||
String outFilePath = FILE_DIR + cacheFileName;
|
||||
|
||||
@@ -12,15 +12,15 @@ import org.springframework.ui.Model;
|
||||
@Service
|
||||
public class Online3DFilePreviewImpl implements FilePreview {
|
||||
|
||||
private final CommonPreviewImpl commonPreview;
|
||||
private final PictureFilePreviewImpl pictureFilePreview;
|
||||
|
||||
public Online3DFilePreviewImpl(CommonPreviewImpl commonPreview) {
|
||||
this.commonPreview = commonPreview;
|
||||
public Online3DFilePreviewImpl(PictureFilePreviewImpl pictureFilePreview) {
|
||||
this.pictureFilePreview = pictureFilePreview;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String filePreviewHandle(String url, Model model, FileAttribute fileAttribute) {
|
||||
commonPreview.filePreviewHandle(url,model,fileAttribute);
|
||||
pictureFilePreview.filePreviewHandle(url,model,fileAttribute);
|
||||
return Online3D_FILE_PAGE;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -18,13 +18,12 @@ import java.util.List;
|
||||
* Content :图片文件处理
|
||||
*/
|
||||
@Service
|
||||
public class PictureFilePreviewImpl extends CommonPreviewImpl {
|
||||
public class PictureFilePreviewImpl implements FilePreview {
|
||||
|
||||
private final FileHandlerService fileHandlerService;
|
||||
private final OtherFilePreviewImpl otherFilePreview;
|
||||
|
||||
public PictureFilePreviewImpl(FileHandlerService fileHandlerService, OtherFilePreviewImpl otherFilePreview) {
|
||||
super(fileHandlerService, otherFilePreview);
|
||||
this.fileHandlerService = fileHandlerService;
|
||||
this.otherFilePreview = otherFilePreview;
|
||||
}
|
||||
@@ -40,8 +39,21 @@ public class PictureFilePreviewImpl extends CommonPreviewImpl {
|
||||
imgUrls.addAll(zipImgUrls);
|
||||
}
|
||||
// 不是http开头,浏览器不能直接访问,需下载到本地
|
||||
super.filePreviewHandle(url, model, fileAttribute);
|
||||
model.addAttribute("imgUrls", imgUrls);
|
||||
if (url != null && !url.toLowerCase().startsWith("http")) {
|
||||
ReturnResponse<String> response = DownloadUtils.downLoad(fileAttribute, null);
|
||||
if (response.isFailure()) {
|
||||
return otherFilePreview.notSupportedFile(model, fileAttribute, response.getMsg());
|
||||
} else {
|
||||
String file = fileHandlerService.getRelativePath(response.getContent());
|
||||
imgUrls.clear();
|
||||
imgUrls.add(file);
|
||||
model.addAttribute("imgUrls", imgUrls);
|
||||
model.addAttribute("currentUrl", file);
|
||||
}
|
||||
} else {
|
||||
model.addAttribute("imgUrls", imgUrls);
|
||||
model.addAttribute("currentUrl", url);
|
||||
}
|
||||
return PICTURE_FILE_PREVIEW_PAGE;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,15 +13,15 @@ import org.springframework.ui.Model;
|
||||
@Service
|
||||
public class SvgFilePreviewImpl implements FilePreview {
|
||||
|
||||
private final CommonPreviewImpl commonPreview;
|
||||
private final PictureFilePreviewImpl pictureFilePreview;
|
||||
|
||||
public SvgFilePreviewImpl(CommonPreviewImpl commonPreview) {
|
||||
this.commonPreview = commonPreview;
|
||||
public SvgFilePreviewImpl(PictureFilePreviewImpl pictureFilePreview) {
|
||||
this.pictureFilePreview = pictureFilePreview;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String filePreviewHandle(String url, Model model, FileAttribute fileAttribute) {
|
||||
commonPreview.filePreviewHandle(url,model,fileAttribute);
|
||||
pictureFilePreview.filePreviewHandle(url,model,fileAttribute);
|
||||
return SVG_FILE_PREVIEW_PAGE;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,15 +13,15 @@ import org.springframework.ui.Model;
|
||||
@Service
|
||||
public class XmindFilePreviewImpl implements FilePreview {
|
||||
|
||||
private final CommonPreviewImpl commonPreview;
|
||||
private final PictureFilePreviewImpl pictureFilePreview;
|
||||
|
||||
public XmindFilePreviewImpl(CommonPreviewImpl commonPreview) {
|
||||
this.commonPreview = commonPreview;
|
||||
public XmindFilePreviewImpl(PictureFilePreviewImpl pictureFilePreview) {
|
||||
this.pictureFilePreview = pictureFilePreview;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String filePreviewHandle(String url, Model model, FileAttribute fileAttribute) {
|
||||
commonPreview.filePreviewHandle(url,model,fileAttribute);
|
||||
pictureFilePreview.filePreviewHandle(url,model,fileAttribute);
|
||||
return XMIND_FILE_PREVIEW_PAGE;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -75,7 +75,7 @@ public class DownloadUtils {
|
||||
response.setMsg(fileName);
|
||||
return response;
|
||||
} catch (IOException | GalimatiasParseException e) {
|
||||
logger.error("文件下载失败,url:{}", urlStr);
|
||||
logger.error("文件下载失败,url:{}", urlStr, e);
|
||||
response.setCode(1);
|
||||
response.setContent(null);
|
||||
if (e instanceof FileNotFoundException) {
|
||||
|
||||
@@ -3,8 +3,6 @@ package cn.keking.utils;
|
||||
import io.mola.galimatias.GalimatiasParseException;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.util.Base64Utils;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.util.HtmlUtils;
|
||||
|
||||
import javax.servlet.ServletRequest;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
@@ -105,30 +103,6 @@ public class WebUtils {
|
||||
return noQueryUrl.substring(noQueryUrl.lastIndexOf("/") + 1);
|
||||
}
|
||||
|
||||
/**
|
||||
* 从url中剥离出文件名
|
||||
* @param file 文件
|
||||
* @return 文件名
|
||||
*/
|
||||
public static String getFileNameFromMultipartFile(MultipartFile file) {
|
||||
String fileName = file.getOriginalFilename();
|
||||
//判断是否为IE浏览器的文件名,IE浏览器下文件名会带有盘符信
|
||||
// escaping dangerous characters to prevent XSS
|
||||
assert fileName != null;
|
||||
fileName = HtmlUtils.htmlEscape(fileName, KkFileUtils.DEFAULT_FILE_ENCODING);
|
||||
|
||||
// Check for Unix-style path
|
||||
int unixSep = fileName.lastIndexOf('/');
|
||||
// Check for Windows-style path
|
||||
int winSep = fileName.lastIndexOf('\\');
|
||||
// Cut off at latest possible point
|
||||
int pos = (Math.max(winSep, unixSep));
|
||||
if (pos != -1) {
|
||||
fileName = fileName.substring(pos + 1);
|
||||
}
|
||||
return fileName;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 从url中获取文件后缀
|
||||
|
||||
@@ -6,26 +6,22 @@ import cn.keking.utils.KkFileUtils;
|
||||
import cn.keking.utils.WebUtils;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.util.ObjectUtils;
|
||||
import org.springframework.util.StreamUtils;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.util.HtmlUtils;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.io.OutputStream;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
import java.nio.file.Files;
|
||||
import java.nio.file.Paths;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Objects;
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* @author yudian-it
|
||||
@@ -40,22 +36,50 @@ public class FileController {
|
||||
private final String demoDir = "demo";
|
||||
private final String demoPath = demoDir + File.separator;
|
||||
public static final String BASE64_DECODE_ERROR_MSG = "Base64解码失败,请检查你的 %s 是否采用 Base64 + urlEncode 双重编码了!";
|
||||
private static final String[] not_allowed = { "dll", "exe", "msi" }; // 不允许上传的文件扩展名
|
||||
|
||||
@PostMapping("/fileUpload")
|
||||
public ReturnResponse<Object> fileUpload(@RequestParam("file") MultipartFile file) {
|
||||
ReturnResponse<Object> checkResult = this.fileUploadCheck(file);
|
||||
if (checkResult.isFailure()) {
|
||||
return checkResult;
|
||||
if (ConfigConstants.getFileUploadDisable()) {
|
||||
return ReturnResponse.failure("文件传接口已禁用");
|
||||
}
|
||||
// 获取文件名
|
||||
String fileName = file.getOriginalFilename();
|
||||
//判断是否为IE浏览器的文件名,IE浏览器下文件名会带有盘符信息
|
||||
|
||||
// escaping dangerous characters to prevent XSS
|
||||
assert fileName != null;
|
||||
fileName = HtmlUtils.htmlEscape(fileName, StandardCharsets.UTF_8.name());
|
||||
|
||||
// Check for Unix-style path
|
||||
int unixSep = fileName.lastIndexOf('/');
|
||||
// Check for Windows-style path
|
||||
int winSep = fileName.lastIndexOf('\\');
|
||||
// Cut off at latest possible point
|
||||
int pos = (Math.max(winSep, unixSep));
|
||||
if (pos != -1) {
|
||||
fileName = fileName.substring(pos + 1);
|
||||
}
|
||||
String fileType= "";
|
||||
int i = fileName.lastIndexOf('.');
|
||||
if (i > 0) {
|
||||
fileType= fileName.substring(i+1);
|
||||
fileType= fileType.toLowerCase();
|
||||
}
|
||||
if (fileType.length() == 0 || fileType.equals("dll") || fileType.equals("exe") || fileType.equals("msi") ){
|
||||
return ReturnResponse.failure(fileName+"不允许上传的文件");
|
||||
}
|
||||
// 判断是否存在同名文件
|
||||
if (existsFile(fileName)) {
|
||||
return ReturnResponse.failure("存在同名文件,请先删除原有文件再次上传");
|
||||
}
|
||||
File outFile = new File(fileDir + demoPath);
|
||||
if (!outFile.exists() && !outFile.mkdirs()) {
|
||||
logger.error("创建文件夹【{}】失败,请检查目录权限!", fileDir + demoPath);
|
||||
}
|
||||
String fileName = checkResult.getContent().toString();
|
||||
logger.info("上传文件:{}{}{}", fileDir, demoPath, fileName);
|
||||
logger.info("上传文件:{}", fileDir + demoPath + fileName);
|
||||
try (InputStream in = file.getInputStream(); OutputStream out = Files.newOutputStream(Paths.get(fileDir + demoPath + fileName))) {
|
||||
StreamUtils.copy(in, out);
|
||||
in.close();
|
||||
out.close();
|
||||
return ReturnResponse.success(null);
|
||||
} catch (IOException e) {
|
||||
logger.error("文件上传失败", e);
|
||||
@@ -65,11 +89,21 @@ public class FileController {
|
||||
|
||||
@GetMapping("/deleteFile")
|
||||
public ReturnResponse<Object> deleteFile(String fileName) {
|
||||
ReturnResponse<Object> checkResult = this.deleteFileCheck(fileName);
|
||||
if (checkResult.isFailure()) {
|
||||
return checkResult;
|
||||
if (fileName == null || fileName.length() == 0) {
|
||||
return ReturnResponse.failure("文件名为空,删除失败!");
|
||||
}
|
||||
try {
|
||||
fileName = WebUtils.decodeUrl(fileName);
|
||||
} catch (Exception ex) {
|
||||
String errorMsg = String.format(BASE64_DECODE_ERROR_MSG, "url");
|
||||
return ReturnResponse.failure(errorMsg+"删除失败!");
|
||||
}
|
||||
if (fileName.contains("/")) {
|
||||
fileName = fileName.substring(fileName.lastIndexOf("/") + 1);
|
||||
}
|
||||
if (KkFileUtils.isIllegalFileName(fileName)) {
|
||||
return ReturnResponse.failure("非法文件名,删除失败!");
|
||||
}
|
||||
fileName = checkResult.getContent().toString();
|
||||
File file = new File(fileDir + demoPath + fileName);
|
||||
logger.info("删除文件:{}", file.getAbsolutePath());
|
||||
if (file.exists() && !file.delete()) {
|
||||
@@ -85,9 +119,7 @@ public class FileController {
|
||||
List<Map<String, String>> list = new ArrayList<>();
|
||||
File file = new File(fileDir + demoPath);
|
||||
if (file.exists()) {
|
||||
File[] files = Objects.requireNonNull(file.listFiles());
|
||||
Arrays.sort(files, (f1, f2) -> Long.compare(f2.lastModified(), f1.lastModified()));
|
||||
Arrays.stream(files).forEach(file1 -> {
|
||||
Arrays.stream(Objects.requireNonNull(file.listFiles())).forEach(file1 -> {
|
||||
Map<String, String> fileName = new HashMap<>();
|
||||
fileName.put("fileName", demoDir + "/" + file1.getName());
|
||||
list.add(fileName);
|
||||
@@ -96,72 +128,6 @@ public class FileController {
|
||||
return list;
|
||||
}
|
||||
|
||||
/**
|
||||
* 上传文件前校验
|
||||
*
|
||||
* @param file 文件
|
||||
* @return 校验结果
|
||||
*/
|
||||
private ReturnResponse<Object> fileUploadCheck(MultipartFile file) {
|
||||
if (ConfigConstants.getFileUploadDisable()) {
|
||||
return ReturnResponse.failure("文件传接口已禁用");
|
||||
}
|
||||
String fileName = WebUtils.getFileNameFromMultipartFile(file);
|
||||
|
||||
if (!isAllowedUpload(fileName)) {
|
||||
return ReturnResponse.failure("不允许上传的文件类型: " + fileName);
|
||||
}
|
||||
if (KkFileUtils.isIllegalFileName(fileName)) {
|
||||
return ReturnResponse.failure("不允许上传的文件名: " + fileName);
|
||||
}
|
||||
// 判断是否存在同名文件
|
||||
if (existsFile(fileName)) {
|
||||
return ReturnResponse.failure("存在同名文件,请先删除原有文件再次上传");
|
||||
}
|
||||
return ReturnResponse.success(fileName);
|
||||
}
|
||||
|
||||
/**
|
||||
* 判断文件是否允许上传
|
||||
*
|
||||
* @param file 文件扩展名
|
||||
* @return 是否允许上传
|
||||
*/
|
||||
private boolean isAllowedUpload(String file) {
|
||||
String fileType = KkFileUtils.suffixFromFileName(file);
|
||||
for (String type : not_allowed) {
|
||||
if (type.equals(fileType))
|
||||
return false;
|
||||
}
|
||||
return !ObjectUtils.isEmpty(fileType);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除文件前校验
|
||||
*
|
||||
* @param fileName 文件名
|
||||
* @return 校验结果
|
||||
*/
|
||||
private ReturnResponse<Object> deleteFileCheck(String fileName) {
|
||||
if (ObjectUtils.isEmpty(fileName)) {
|
||||
return ReturnResponse.failure("文件名为空,删除失败!");
|
||||
}
|
||||
try {
|
||||
fileName = WebUtils.decodeUrl(fileName);
|
||||
} catch (Exception ex) {
|
||||
String errorMsg = String.format(BASE64_DECODE_ERROR_MSG, fileName);
|
||||
return ReturnResponse.failure(errorMsg + "删除失败!");
|
||||
}
|
||||
assert fileName != null;
|
||||
if (fileName.contains("/")) {
|
||||
fileName = fileName.substring(fileName.lastIndexOf("/") + 1);
|
||||
}
|
||||
if (KkFileUtils.isIllegalFileName(fileName)) {
|
||||
return ReturnResponse.failure("非法文件名,删除失败!");
|
||||
}
|
||||
return ReturnResponse.success(fileName);
|
||||
}
|
||||
|
||||
private boolean existsFile(String fileName) {
|
||||
File file = new File(fileDir + demoPath + fileName);
|
||||
return file.exists();
|
||||
|
||||
@@ -13,28 +13,21 @@ public class IndexController {
|
||||
|
||||
@GetMapping( "/index")
|
||||
public String go2Index(){
|
||||
return "/main/index";
|
||||
return "index";
|
||||
}
|
||||
|
||||
@GetMapping( "/record")
|
||||
public String go2Record(){
|
||||
return "/main/record";
|
||||
return "record";
|
||||
}
|
||||
|
||||
@GetMapping( "/sponsor")
|
||||
public String go2Sponsor(){
|
||||
return "/main/sponsor";
|
||||
}
|
||||
|
||||
@GetMapping( "/integrated")
|
||||
public String go2Integrated(){
|
||||
return "/main/integrated";
|
||||
@GetMapping( "/comment")
|
||||
public String go2Comment(){
|
||||
return "comment";
|
||||
}
|
||||
|
||||
@GetMapping( "/")
|
||||
public String root() {
|
||||
return "/main/index";
|
||||
return "redirect:/index";
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -42,9 +42,7 @@ public class TrustHostFilter implements Filter {
|
||||
response.getWriter().write(html);
|
||||
response.getWriter().close();
|
||||
}
|
||||
else {
|
||||
chain.doFilter(request, response);
|
||||
}
|
||||
chain.doFilter(request, response);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -1,144 +0,0 @@
|
||||
.bjs-container {
|
||||
--bjs-font-family: Arial, sans-serif;
|
||||
|
||||
--color-grey-225-10-15: hsl(225, 10%, 15%);
|
||||
--color-grey-225-10-35: hsl(225, 10%, 35%);
|
||||
--color-grey-225-10-55: hsl(225, 10%, 55%);
|
||||
--color-grey-225-10-75: hsl(225, 10%, 75%);
|
||||
--color-grey-225-10-80: hsl(225, 10%, 80%);
|
||||
--color-grey-225-10-85: hsl(225, 10%, 85%);
|
||||
--color-grey-225-10-90: hsl(225, 10%, 90%);
|
||||
--color-grey-225-10-95: hsl(225, 10%, 95%);
|
||||
--color-grey-225-10-97: hsl(225, 10%, 97%);
|
||||
|
||||
--color-blue-205-100-45: hsl(205, 100%, 45%);
|
||||
--color-blue-205-100-45-opacity-30: hsla(205, 100%, 45%, 30%);
|
||||
--color-blue-205-100-50: hsl(205, 100%, 50%);
|
||||
--color-blue-205-100-95: hsl(205, 100%, 95%);
|
||||
|
||||
--color-green-150-86-44: hsl(150, 86%, 44%);
|
||||
|
||||
--color-red-360-100-40: hsl(360, 100%, 40%);
|
||||
--color-red-360-100-45: hsl(360, 100%, 45%);
|
||||
--color-red-360-100-92: hsl(360, 100%, 92%);
|
||||
--color-red-360-100-97: hsl(360, 100%, 97%);
|
||||
|
||||
--color-white: hsl(0, 0%, 100%);
|
||||
--color-black: hsl(0, 0%, 0%);
|
||||
--color-black-opacity-05: hsla(0, 0%, 0%, 5%);
|
||||
--color-black-opacity-10: hsla(0, 0%, 0%, 10%);
|
||||
|
||||
--breadcrumbs-font-family: var(--bjs-font-family);
|
||||
--breadcrumbs-item-color: var(--color-blue-205-100-50);
|
||||
--breadcrumbs-arrow-color: var(--color-black);
|
||||
--drilldown-fill-color: var(--color-white);
|
||||
--drilldown-background-color: var(--color-blue-205-100-50);
|
||||
}
|
||||
|
||||
.bjs-breadcrumbs {
|
||||
position: absolute;
|
||||
display: none;
|
||||
flex-wrap: wrap;
|
||||
align-items: center;
|
||||
top: 30px;
|
||||
left: 30px;
|
||||
padding: 0px;
|
||||
margin: 0px;
|
||||
font-family: var(--breadcrumbs-font-family);
|
||||
font-size: 16px;
|
||||
line-height: normal;
|
||||
}
|
||||
|
||||
.bjs-breadcrumbs-shown .bjs-breadcrumbs {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.djs-palette-shown .bjs-breadcrumbs {
|
||||
left: 90px;
|
||||
}
|
||||
|
||||
.djs-palette-shown.djs-palette-two-column .bjs-breadcrumbs {
|
||||
left: 140px;
|
||||
}
|
||||
|
||||
.bjs-breadcrumbs li {
|
||||
display: inline-flex;
|
||||
padding-bottom: 5px;
|
||||
}
|
||||
|
||||
.bjs-breadcrumbs li a {
|
||||
cursor: pointer;
|
||||
color: var(--breadcrumbs-item-color);
|
||||
}
|
||||
|
||||
.bjs-breadcrumbs li:last-of-type a {
|
||||
color: inherit;
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
.bjs-breadcrumbs li:not(:first-child)::before {
|
||||
content: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="17" height="17" viewBox="0 0 24 24"><path d="M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z" /><path d="M0 0h24v24H0z" fill="none" /></svg>');
|
||||
padding: 0 8px;
|
||||
color: var(--breadcrumbs-arrow-color);
|
||||
height: 1em;
|
||||
}
|
||||
|
||||
.bjs-breadcrumbs .bjs-crumb {
|
||||
display: inline-block;
|
||||
max-width: 200px;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.bjs-drilldown {
|
||||
width: 20px;
|
||||
height: 20px;
|
||||
|
||||
padding: 0px;
|
||||
margin-left: -20px;
|
||||
|
||||
cursor: pointer;
|
||||
border: none;
|
||||
border-radius: 2px;
|
||||
outline: none;
|
||||
|
||||
fill: var(--drilldown-fill-color);
|
||||
background-color: var(--drilldown-background-color);
|
||||
}
|
||||
|
||||
.bjs-drilldown-empty {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.selected .bjs-drilldown-empty {
|
||||
display: inherit;
|
||||
}
|
||||
|
||||
[data-popup="align-elements"] .djs-popup-results {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
[data-popup="align-elements"] .djs-popup-body [data-group] + [data-group] {
|
||||
border-left: 1px solid var(--popup-border-color);
|
||||
}
|
||||
|
||||
[data-popup="align-elements"] [data-group="align"] {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, 1fr);
|
||||
}
|
||||
|
||||
[data-popup="align-elements"] .djs-popup-body .entry {
|
||||
padding: 6px 8px;
|
||||
}
|
||||
|
||||
[data-popup="align-elements"] .djs-popup-body .entry:not(:first-child) {
|
||||
margin-top: 0;
|
||||
}
|
||||
|
||||
[data-popup="align-elements"] .djs-popup-entry-icon {
|
||||
display: block;
|
||||
margin: 0;
|
||||
height: 20px;
|
||||
width: 20px;
|
||||
}
|
||||
File diff suppressed because one or more lines are too long
@@ -1,163 +0,0 @@
|
||||
@font-face {
|
||||
font-family: 'bpmn';
|
||||
src: url('../font/bpmn.eot?21877404');
|
||||
src: url('../font/bpmn.eot?21877404#iefix') format('embedded-opentype'),
|
||||
url('../font/bpmn.woff2?21877404') format('woff2'),
|
||||
url('../font/bpmn.woff?21877404') format('woff'),
|
||||
url('../font/bpmn.ttf?21877404') format('truetype'),
|
||||
url('../font/bpmn.svg?21877404#bpmn') format('svg');
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
/* Chrome hack: SVG is rendered more smooth in Windozze. 100% magic, uncomment if you need it. */
|
||||
/* Note, that will break hinting! In other OS-es font will be not as sharp as it could be */
|
||||
/*
|
||||
@media screen and (-webkit-min-device-pixel-ratio:0) {
|
||||
@font-face {
|
||||
font-family: 'bpmn';
|
||||
src: url('../font/bpmn.svg?21877404#bpmn') format('svg');
|
||||
}
|
||||
}
|
||||
*/
|
||||
[class^="bpmn-icon-"]:before, [class*=" bpmn-icon-"]:before {
|
||||
font-family: "bpmn";
|
||||
font-style: normal;
|
||||
font-weight: normal;
|
||||
speak: never;
|
||||
|
||||
display: inline-block;
|
||||
text-decoration: inherit;
|
||||
width: 1em;
|
||||
/* margin-right: .2em; */
|
||||
text-align: center;
|
||||
/* opacity: .8; */
|
||||
|
||||
/* For safety - reset parent styles, that can break glyph codes*/
|
||||
font-variant: normal;
|
||||
text-transform: none;
|
||||
|
||||
/* fix buttons height, for twitter bootstrap */
|
||||
line-height: 1em;
|
||||
|
||||
/* Animation center compensation - margins should be symmetric */
|
||||
/* remove if not needed */
|
||||
/* margin-left: .2em; */
|
||||
|
||||
/* you can be more comfortable with increased icons size */
|
||||
/* font-size: 120%; */
|
||||
|
||||
/* Font smoothing. That was taken from TWBS */
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
|
||||
/* Uncomment for 3D effect */
|
||||
/* text-shadow: 1px 1px 1px rgba(127, 127, 127, 0.3); */
|
||||
}
|
||||
|
||||
.bpmn-icon-trash:before { content: '\e801'; } /* '' */
|
||||
.bpmn-icon-gateway-parallel:before { content: '\e804'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-cancel:before { content: '\e805'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-message:before { content: '\e806'; } /* '' */
|
||||
.bpmn-icon-start-event-compensation:before { content: '\e807'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-parallel-multiple:before { content: '\e808'; } /* '' */
|
||||
.bpmn-icon-loop-marker:before { content: '\e809'; } /* '' */
|
||||
.bpmn-icon-parallel-mi-marker:before { content: '\e80a'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-signal:before { content: '\e80b'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-timer:before { content: '\e80c'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-parallel-multiple:before { content: '\e80d'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-compensation:before { content: '\e80e'; } /* '' */
|
||||
.bpmn-icon-gateway-xor:before { content: '\e80f'; } /* '' */
|
||||
.bpmn-icon-end-event-cancel:before { content: '\e811'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-condition:before { content: '\e812'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-parallel-multiple:before { content: '\e813'; } /* '' */
|
||||
.bpmn-icon-start-event-condition:before { content: '\e814'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-timer:before { content: '\e815'; } /* '' */
|
||||
.bpmn-icon-sequential-mi-marker:before { content: '\e816'; } /* '' */
|
||||
.bpmn-icon-user-task:before { content: '\e817'; } /* '' */
|
||||
.bpmn-icon-business-rule:before { content: '\e818'; } /* '' */
|
||||
.bpmn-icon-sub-process-marker:before { content: '\e819'; } /* '' */
|
||||
.bpmn-icon-start-event-parallel-multiple:before { content: '\e81a'; } /* '' */
|
||||
.bpmn-icon-start-event-error:before { content: '\e81b'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-signal:before { content: '\e81c'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-error:before { content: '\e81d'; } /* '' */
|
||||
.bpmn-icon-end-event-compensation:before { content: '\e81e'; } /* '' */
|
||||
.bpmn-icon-subprocess-collapsed:before { content: '\e81f'; } /* '' */
|
||||
.bpmn-icon-subprocess-expanded:before { content: '\e820'; } /* '' */
|
||||
.bpmn-icon-task:before { content: '\e821'; } /* '' */
|
||||
.bpmn-icon-end-event-error:before { content: '\e822'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-escalation:before { content: '\e823'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-timer:before { content: '\e824'; } /* '' */
|
||||
.bpmn-icon-start-event-escalation:before { content: '\e825'; } /* '' */
|
||||
.bpmn-icon-start-event-signal:before { content: '\e826'; } /* '' */
|
||||
.bpmn-icon-business-rule-task:before { content: '\e827'; } /* '' */
|
||||
.bpmn-icon-manual:before { content: '\e828'; } /* '' */
|
||||
.bpmn-icon-receive:before { content: '\e829'; } /* '' */
|
||||
.bpmn-icon-call-activity:before { content: '\e82a'; } /* '' */
|
||||
.bpmn-icon-start-event-timer:before { content: '\e82b'; } /* '' */
|
||||
.bpmn-icon-start-event-message:before { content: '\e82c'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-none:before { content: '\e82d'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-link:before { content: '\e82e'; } /* '' */
|
||||
.bpmn-icon-end-event-escalation:before { content: '\e82f'; } /* '' */
|
||||
.bpmn-icon-bpmn-io:before { content: '\e831'; } /* '' */
|
||||
.bpmn-icon-gateway-complex:before { content: '\e832'; } /* '' */
|
||||
.bpmn-icon-gateway-eventbased:before { content: '\e833'; } /* '' */
|
||||
.bpmn-icon-gateway-none:before { content: '\e834'; } /* '' */
|
||||
.bpmn-icon-gateway-or:before { content: '\e835'; } /* '' */
|
||||
.bpmn-icon-end-event-terminate:before { content: '\e836'; } /* '' */
|
||||
.bpmn-icon-end-event-signal:before { content: '\e837'; } /* '' */
|
||||
.bpmn-icon-end-event-none:before { content: '\e838'; } /* '' */
|
||||
.bpmn-icon-end-event-multiple:before { content: '\e839'; } /* '' */
|
||||
.bpmn-icon-end-event-message:before { content: '\e83a'; } /* '' */
|
||||
.bpmn-icon-end-event-link:before { content: '\e83b'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-message:before { content: '\e83c'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-compensation:before { content: '\e83d'; } /* '' */
|
||||
.bpmn-icon-start-event-multiple:before { content: '\e83e'; } /* '' */
|
||||
.bpmn-icon-script:before { content: '\e83f'; } /* '' */
|
||||
.bpmn-icon-manual-task:before { content: '\e840'; } /* '' */
|
||||
.bpmn-icon-send:before { content: '\e841'; } /* '' */
|
||||
.bpmn-icon-service:before { content: '\e842'; } /* '' */
|
||||
.bpmn-icon-receive-task:before { content: '\e843'; } /* '' */
|
||||
.bpmn-icon-user:before { content: '\e844'; } /* '' */
|
||||
.bpmn-icon-start-event-none:before { content: '\e845'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-escalation:before { content: '\e846'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-multiple:before { content: '\e847'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-escalation:before { content: '\e848'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-link:before { content: '\e849'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-condition:before { content: '\e84a'; } /* '' */
|
||||
.bpmn-icon-data-object:before { content: '\e84b'; } /* '' */
|
||||
.bpmn-icon-script-task:before { content: '\e84c'; } /* '' */
|
||||
.bpmn-icon-send-task:before { content: '\e84d'; } /* '' */
|
||||
.bpmn-icon-data-store:before { content: '\e84e'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-escalation:before { content: '\e84f'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-message:before { content: '\e850'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-multiple:before { content: '\e851'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-signal:before { content: '\e852'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-multiple:before { content: '\e853'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-message:before { content: '\e854'; } /* '' */
|
||||
.bpmn-icon-ad-hoc-marker:before { content: '\e855'; } /* '' */
|
||||
.bpmn-icon-service-task:before { content: '\e856'; } /* '' */
|
||||
.bpmn-icon-task-none:before { content: '\e857'; } /* '' */
|
||||
.bpmn-icon-compensation-marker:before { content: '\e858'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-multiple:before { content: '\e859'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-signal:before { content: '\e85a'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-condition:before { content: '\e85b'; } /* '' */
|
||||
.bpmn-icon-participant:before { content: '\e85c'; } /* '' */
|
||||
.bpmn-icon-event-subprocess-expanded:before { content: '\e85d'; } /* '' */
|
||||
.bpmn-icon-lane-insert-below:before { content: '\e85e'; } /* '' */
|
||||
.bpmn-icon-space-tool:before { content: '\e85f'; } /* '' */
|
||||
.bpmn-icon-connection-multi:before { content: '\e860'; } /* '' */
|
||||
.bpmn-icon-lane:before { content: '\e861'; } /* '' */
|
||||
.bpmn-icon-lasso-tool:before { content: '\e862'; } /* '' */
|
||||
.bpmn-icon-lane-insert-above:before { content: '\e863'; } /* '' */
|
||||
.bpmn-icon-lane-divide-three:before { content: '\e864'; } /* '' */
|
||||
.bpmn-icon-lane-divide-two:before { content: '\e865'; } /* '' */
|
||||
.bpmn-icon-data-input:before { content: '\e866'; } /* '' */
|
||||
.bpmn-icon-data-output:before { content: '\e867'; } /* '' */
|
||||
.bpmn-icon-hand-tool:before { content: '\e868'; } /* '' */
|
||||
.bpmn-icon-group:before { content: '\e869'; } /* '' */
|
||||
.bpmn-icon-text-annotation:before { content: '\e86b'; } /* '' */
|
||||
.bpmn-icon-transaction:before { content: '\e8c4'; } /* '' */
|
||||
.bpmn-icon-screw-wrench:before { content: '\e8db'; } /* '' */
|
||||
.bpmn-icon-connection:before { content: '\e8dc'; } /* '' */
|
||||
.bpmn-icon-conditional-flow:before { content: '\e8e0'; } /* '' */
|
||||
.bpmn-icon-default-flow:before { content: '\e8e1'; } /* '' */
|
||||
@@ -1,108 +0,0 @@
|
||||
|
||||
.bpmn-icon-trash:before { content: '\e801'; } /* '' */
|
||||
.bpmn-icon-gateway-parallel:before { content: '\e804'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-cancel:before { content: '\e805'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-message:before { content: '\e806'; } /* '' */
|
||||
.bpmn-icon-start-event-compensation:before { content: '\e807'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-parallel-multiple:before { content: '\e808'; } /* '' */
|
||||
.bpmn-icon-loop-marker:before { content: '\e809'; } /* '' */
|
||||
.bpmn-icon-parallel-mi-marker:before { content: '\e80a'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-signal:before { content: '\e80b'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-timer:before { content: '\e80c'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-parallel-multiple:before { content: '\e80d'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-compensation:before { content: '\e80e'; } /* '' */
|
||||
.bpmn-icon-gateway-xor:before { content: '\e80f'; } /* '' */
|
||||
.bpmn-icon-end-event-cancel:before { content: '\e811'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-condition:before { content: '\e812'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-parallel-multiple:before { content: '\e813'; } /* '' */
|
||||
.bpmn-icon-start-event-condition:before { content: '\e814'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-timer:before { content: '\e815'; } /* '' */
|
||||
.bpmn-icon-sequential-mi-marker:before { content: '\e816'; } /* '' */
|
||||
.bpmn-icon-user-task:before { content: '\e817'; } /* '' */
|
||||
.bpmn-icon-business-rule:before { content: '\e818'; } /* '' */
|
||||
.bpmn-icon-sub-process-marker:before { content: '\e819'; } /* '' */
|
||||
.bpmn-icon-start-event-parallel-multiple:before { content: '\e81a'; } /* '' */
|
||||
.bpmn-icon-start-event-error:before { content: '\e81b'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-signal:before { content: '\e81c'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-error:before { content: '\e81d'; } /* '' */
|
||||
.bpmn-icon-end-event-compensation:before { content: '\e81e'; } /* '' */
|
||||
.bpmn-icon-subprocess-collapsed:before { content: '\e81f'; } /* '' */
|
||||
.bpmn-icon-subprocess-expanded:before { content: '\e820'; } /* '' */
|
||||
.bpmn-icon-task:before { content: '\e821'; } /* '' */
|
||||
.bpmn-icon-end-event-error:before { content: '\e822'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-escalation:before { content: '\e823'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-timer:before { content: '\e824'; } /* '' */
|
||||
.bpmn-icon-start-event-escalation:before { content: '\e825'; } /* '' */
|
||||
.bpmn-icon-start-event-signal:before { content: '\e826'; } /* '' */
|
||||
.bpmn-icon-business-rule-task:before { content: '\e827'; } /* '' */
|
||||
.bpmn-icon-manual:before { content: '\e828'; } /* '' */
|
||||
.bpmn-icon-receive:before { content: '\e829'; } /* '' */
|
||||
.bpmn-icon-call-activity:before { content: '\e82a'; } /* '' */
|
||||
.bpmn-icon-start-event-timer:before { content: '\e82b'; } /* '' */
|
||||
.bpmn-icon-start-event-message:before { content: '\e82c'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-none:before { content: '\e82d'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-link:before { content: '\e82e'; } /* '' */
|
||||
.bpmn-icon-end-event-escalation:before { content: '\e82f'; } /* '' */
|
||||
.bpmn-icon-bpmn-io:before { content: '\e831'; } /* '' */
|
||||
.bpmn-icon-gateway-complex:before { content: '\e832'; } /* '' */
|
||||
.bpmn-icon-gateway-eventbased:before { content: '\e833'; } /* '' */
|
||||
.bpmn-icon-gateway-none:before { content: '\e834'; } /* '' */
|
||||
.bpmn-icon-gateway-or:before { content: '\e835'; } /* '' */
|
||||
.bpmn-icon-end-event-terminate:before { content: '\e836'; } /* '' */
|
||||
.bpmn-icon-end-event-signal:before { content: '\e837'; } /* '' */
|
||||
.bpmn-icon-end-event-none:before { content: '\e838'; } /* '' */
|
||||
.bpmn-icon-end-event-multiple:before { content: '\e839'; } /* '' */
|
||||
.bpmn-icon-end-event-message:before { content: '\e83a'; } /* '' */
|
||||
.bpmn-icon-end-event-link:before { content: '\e83b'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-message:before { content: '\e83c'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-compensation:before { content: '\e83d'; } /* '' */
|
||||
.bpmn-icon-start-event-multiple:before { content: '\e83e'; } /* '' */
|
||||
.bpmn-icon-script:before { content: '\e83f'; } /* '' */
|
||||
.bpmn-icon-manual-task:before { content: '\e840'; } /* '' */
|
||||
.bpmn-icon-send:before { content: '\e841'; } /* '' */
|
||||
.bpmn-icon-service:before { content: '\e842'; } /* '' */
|
||||
.bpmn-icon-receive-task:before { content: '\e843'; } /* '' */
|
||||
.bpmn-icon-user:before { content: '\e844'; } /* '' */
|
||||
.bpmn-icon-start-event-none:before { content: '\e845'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-escalation:before { content: '\e846'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-multiple:before { content: '\e847'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-escalation:before { content: '\e848'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-link:before { content: '\e849'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-condition:before { content: '\e84a'; } /* '' */
|
||||
.bpmn-icon-data-object:before { content: '\e84b'; } /* '' */
|
||||
.bpmn-icon-script-task:before { content: '\e84c'; } /* '' */
|
||||
.bpmn-icon-send-task:before { content: '\e84d'; } /* '' */
|
||||
.bpmn-icon-data-store:before { content: '\e84e'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-escalation:before { content: '\e84f'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-message:before { content: '\e850'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-multiple:before { content: '\e851'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-signal:before { content: '\e852'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-multiple:before { content: '\e853'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-message:before { content: '\e854'; } /* '' */
|
||||
.bpmn-icon-ad-hoc-marker:before { content: '\e855'; } /* '' */
|
||||
.bpmn-icon-service-task:before { content: '\e856'; } /* '' */
|
||||
.bpmn-icon-task-none:before { content: '\e857'; } /* '' */
|
||||
.bpmn-icon-compensation-marker:before { content: '\e858'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-multiple:before { content: '\e859'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-signal:before { content: '\e85a'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-condition:before { content: '\e85b'; } /* '' */
|
||||
.bpmn-icon-participant:before { content: '\e85c'; } /* '' */
|
||||
.bpmn-icon-event-subprocess-expanded:before { content: '\e85d'; } /* '' */
|
||||
.bpmn-icon-lane-insert-below:before { content: '\e85e'; } /* '' */
|
||||
.bpmn-icon-space-tool:before { content: '\e85f'; } /* '' */
|
||||
.bpmn-icon-connection-multi:before { content: '\e860'; } /* '' */
|
||||
.bpmn-icon-lane:before { content: '\e861'; } /* '' */
|
||||
.bpmn-icon-lasso-tool:before { content: '\e862'; } /* '' */
|
||||
.bpmn-icon-lane-insert-above:before { content: '\e863'; } /* '' */
|
||||
.bpmn-icon-lane-divide-three:before { content: '\e864'; } /* '' */
|
||||
.bpmn-icon-lane-divide-two:before { content: '\e865'; } /* '' */
|
||||
.bpmn-icon-data-input:before { content: '\e866'; } /* '' */
|
||||
.bpmn-icon-data-output:before { content: '\e867'; } /* '' */
|
||||
.bpmn-icon-hand-tool:before { content: '\e868'; } /* '' */
|
||||
.bpmn-icon-group:before { content: '\e869'; } /* '' */
|
||||
.bpmn-icon-text-annotation:before { content: '\e86b'; } /* '' */
|
||||
.bpmn-icon-transaction:before { content: '\e8c4'; } /* '' */
|
||||
.bpmn-icon-screw-wrench:before { content: '\e8db'; } /* '' */
|
||||
.bpmn-icon-connection:before { content: '\e8dc'; } /* '' */
|
||||
.bpmn-icon-conditional-flow:before { content: '\e8e0'; } /* '' */
|
||||
.bpmn-icon-default-flow:before { content: '\e8e1'; } /* '' */
|
||||
File diff suppressed because one or more lines are too long
@@ -1,163 +0,0 @@
|
||||
@font-face {
|
||||
font-family: 'bpmn';
|
||||
src: url('../font/bpmn.eot?21877404');
|
||||
src: url('../font/bpmn.eot?21877404#iefix') format('embedded-opentype'),
|
||||
url('../font/bpmn.woff2?21877404') format('woff2'),
|
||||
url('../font/bpmn.woff?21877404') format('woff'),
|
||||
url('../font/bpmn.ttf?21877404') format('truetype'),
|
||||
url('../font/bpmn.svg?21877404#bpmn') format('svg');
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
}
|
||||
/* Chrome hack: SVG is rendered more smooth in Windozze. 100% magic, uncomment if you need it. */
|
||||
/* Note, that will break hinting! In other OS-es font will be not as sharp as it could be */
|
||||
/*
|
||||
@media screen and (-webkit-min-device-pixel-ratio:0) {
|
||||
@font-face {
|
||||
font-family: 'bpmn';
|
||||
src: url('../font/bpmn.svg?21877404#bpmn') format('svg');
|
||||
}
|
||||
}
|
||||
*/
|
||||
[class^="bpmn-icon-"]:before, [class*=" bpmn-icon-"]:before {
|
||||
font-family: "bpmn";
|
||||
font-style: normal;
|
||||
font-weight: normal;
|
||||
speak: never;
|
||||
|
||||
display: inline-block;
|
||||
text-decoration: inherit;
|
||||
width: 1em;
|
||||
/* margin-right: .2em; */
|
||||
text-align: center;
|
||||
/* opacity: .8; */
|
||||
|
||||
/* For safety - reset parent styles, that can break glyph codes*/
|
||||
font-variant: normal;
|
||||
text-transform: none;
|
||||
|
||||
/* fix buttons height, for twitter bootstrap */
|
||||
line-height: 1em;
|
||||
|
||||
/* Animation center compensation - margins should be symmetric */
|
||||
/* remove if not needed */
|
||||
/* margin-left: .2em; */
|
||||
|
||||
/* you can be more comfortable with increased icons size */
|
||||
/* font-size: 120%; */
|
||||
|
||||
/* Font smoothing. That was taken from TWBS */
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
|
||||
/* Uncomment for 3D effect */
|
||||
/* text-shadow: 1px 1px 1px rgba(127, 127, 127, 0.3); */
|
||||
}
|
||||
|
||||
.bpmn-icon-trash:before { content: '\e801'; } /* '' */
|
||||
.bpmn-icon-gateway-parallel:before { content: '\e804'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-cancel:before { content: '\e805'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-message:before { content: '\e806'; } /* '' */
|
||||
.bpmn-icon-start-event-compensation:before { content: '\e807'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-parallel-multiple:before { content: '\e808'; } /* '' */
|
||||
.bpmn-icon-loop-marker:before { content: '\e809'; } /* '' */
|
||||
.bpmn-icon-parallel-mi-marker:before { content: '\e80a'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-signal:before { content: '\e80b'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-timer:before { content: '\e80c'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-parallel-multiple:before { content: '\e80d'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-compensation:before { content: '\e80e'; } /* '' */
|
||||
.bpmn-icon-gateway-xor:before { content: '\e80f'; } /* '' */
|
||||
.bpmn-icon-end-event-cancel:before { content: '\e811'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-condition:before { content: '\e812'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-parallel-multiple:before { content: '\e813'; } /* '' */
|
||||
.bpmn-icon-start-event-condition:before { content: '\e814'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-timer:before { content: '\e815'; } /* '' */
|
||||
.bpmn-icon-sequential-mi-marker:before { content: '\e816'; } /* '' */
|
||||
.bpmn-icon-user-task:before { content: '\e817'; } /* '' */
|
||||
.bpmn-icon-business-rule:before { content: '\e818'; } /* '' */
|
||||
.bpmn-icon-sub-process-marker:before { content: '\e819'; } /* '' */
|
||||
.bpmn-icon-start-event-parallel-multiple:before { content: '\e81a'; } /* '' */
|
||||
.bpmn-icon-start-event-error:before { content: '\e81b'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-signal:before { content: '\e81c'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-error:before { content: '\e81d'; } /* '' */
|
||||
.bpmn-icon-end-event-compensation:before { content: '\e81e'; } /* '' */
|
||||
.bpmn-icon-subprocess-collapsed:before { content: '\e81f'; } /* '' */
|
||||
.bpmn-icon-subprocess-expanded:before { content: '\e820'; } /* '' */
|
||||
.bpmn-icon-task:before { content: '\e821'; } /* '' */
|
||||
.bpmn-icon-end-event-error:before { content: '\e822'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-escalation:before { content: '\e823'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-timer:before { content: '\e824'; } /* '' */
|
||||
.bpmn-icon-start-event-escalation:before { content: '\e825'; } /* '' */
|
||||
.bpmn-icon-start-event-signal:before { content: '\e826'; } /* '' */
|
||||
.bpmn-icon-business-rule-task:before { content: '\e827'; } /* '' */
|
||||
.bpmn-icon-manual:before { content: '\e828'; } /* '' */
|
||||
.bpmn-icon-receive:before { content: '\e829'; } /* '' */
|
||||
.bpmn-icon-call-activity:before { content: '\e82a'; } /* '' */
|
||||
.bpmn-icon-start-event-timer:before { content: '\e82b'; } /* '' */
|
||||
.bpmn-icon-start-event-message:before { content: '\e82c'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-none:before { content: '\e82d'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-link:before { content: '\e82e'; } /* '' */
|
||||
.bpmn-icon-end-event-escalation:before { content: '\e82f'; } /* '' */
|
||||
.bpmn-icon-bpmn-io:before { content: '\e831'; } /* '' */
|
||||
.bpmn-icon-gateway-complex:before { content: '\e832'; } /* '' */
|
||||
.bpmn-icon-gateway-eventbased:before { content: '\e833'; } /* '' */
|
||||
.bpmn-icon-gateway-none:before { content: '\e834'; } /* '' */
|
||||
.bpmn-icon-gateway-or:before { content: '\e835'; } /* '' */
|
||||
.bpmn-icon-end-event-terminate:before { content: '\e836'; } /* '' */
|
||||
.bpmn-icon-end-event-signal:before { content: '\e837'; } /* '' */
|
||||
.bpmn-icon-end-event-none:before { content: '\e838'; } /* '' */
|
||||
.bpmn-icon-end-event-multiple:before { content: '\e839'; } /* '' */
|
||||
.bpmn-icon-end-event-message:before { content: '\e83a'; } /* '' */
|
||||
.bpmn-icon-end-event-link:before { content: '\e83b'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-message:before { content: '\e83c'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-compensation:before { content: '\e83d'; } /* '' */
|
||||
.bpmn-icon-start-event-multiple:before { content: '\e83e'; } /* '' */
|
||||
.bpmn-icon-script:before { content: '\e83f'; } /* '' */
|
||||
.bpmn-icon-manual-task:before { content: '\e840'; } /* '' */
|
||||
.bpmn-icon-send:before { content: '\e841'; } /* '' */
|
||||
.bpmn-icon-service:before { content: '\e842'; } /* '' */
|
||||
.bpmn-icon-receive-task:before { content: '\e843'; } /* '' */
|
||||
.bpmn-icon-user:before { content: '\e844'; } /* '' */
|
||||
.bpmn-icon-start-event-none:before { content: '\e845'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-escalation:before { content: '\e846'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-multiple:before { content: '\e847'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-escalation:before { content: '\e848'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-link:before { content: '\e849'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-condition:before { content: '\e84a'; } /* '' */
|
||||
.bpmn-icon-data-object:before { content: '\e84b'; } /* '' */
|
||||
.bpmn-icon-script-task:before { content: '\e84c'; } /* '' */
|
||||
.bpmn-icon-send-task:before { content: '\e84d'; } /* '' */
|
||||
.bpmn-icon-data-store:before { content: '\e84e'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-escalation:before { content: '\e84f'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-message:before { content: '\e850'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-multiple:before { content: '\e851'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-signal:before { content: '\e852'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-multiple:before { content: '\e853'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-message:before { content: '\e854'; } /* '' */
|
||||
.bpmn-icon-ad-hoc-marker:before { content: '\e855'; } /* '' */
|
||||
.bpmn-icon-service-task:before { content: '\e856'; } /* '' */
|
||||
.bpmn-icon-task-none:before { content: '\e857'; } /* '' */
|
||||
.bpmn-icon-compensation-marker:before { content: '\e858'; } /* '' */
|
||||
.bpmn-icon-start-event-non-interrupting-multiple:before { content: '\e859'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-throw-signal:before { content: '\e85a'; } /* '' */
|
||||
.bpmn-icon-intermediate-event-catch-non-interrupting-condition:before { content: '\e85b'; } /* '' */
|
||||
.bpmn-icon-participant:before { content: '\e85c'; } /* '' */
|
||||
.bpmn-icon-event-subprocess-expanded:before { content: '\e85d'; } /* '' */
|
||||
.bpmn-icon-lane-insert-below:before { content: '\e85e'; } /* '' */
|
||||
.bpmn-icon-space-tool:before { content: '\e85f'; } /* '' */
|
||||
.bpmn-icon-connection-multi:before { content: '\e860'; } /* '' */
|
||||
.bpmn-icon-lane:before { content: '\e861'; } /* '' */
|
||||
.bpmn-icon-lasso-tool:before { content: '\e862'; } /* '' */
|
||||
.bpmn-icon-lane-insert-above:before { content: '\e863'; } /* '' */
|
||||
.bpmn-icon-lane-divide-three:before { content: '\e864'; } /* '' */
|
||||
.bpmn-icon-lane-divide-two:before { content: '\e865'; } /* '' */
|
||||
.bpmn-icon-data-input:before { content: '\e866'; } /* '' */
|
||||
.bpmn-icon-data-output:before { content: '\e867'; } /* '' */
|
||||
.bpmn-icon-hand-tool:before { content: '\e868'; } /* '' */
|
||||
.bpmn-icon-group:before { content: '\e869'; } /* '' */
|
||||
.bpmn-icon-text-annotation:before { content: '\e86b'; } /* '' */
|
||||
.bpmn-icon-transaction:before { content: '\e8c4'; } /* '' */
|
||||
.bpmn-icon-screw-wrench:before { content: '\e8db'; } /* '' */
|
||||
.bpmn-icon-connection:before { content: '\e8dc'; } /* '' */
|
||||
.bpmn-icon-conditional-flow:before { content: '\e8e0'; } /* '' */
|
||||
.bpmn-icon-default-flow:before { content: '\e8e1'; } /* '' */
|
||||
@@ -1,986 +0,0 @@
|
||||
/**
|
||||
* color definitions
|
||||
*/
|
||||
.djs-parent {
|
||||
--color-grey-225-10-15: hsl(225, 10%, 15%);
|
||||
--color-grey-225-10-35: hsl(225, 10%, 35%);
|
||||
--color-grey-225-10-55: hsl(225, 10%, 55%);
|
||||
--color-grey-225-10-75: hsl(225, 10%, 75%);
|
||||
--color-grey-225-10-80: hsl(225, 10%, 80%);
|
||||
--color-grey-225-10-85: hsl(225, 10%, 85%);
|
||||
--color-grey-225-10-90: hsl(225, 10%, 90%);
|
||||
--color-grey-225-10-95: hsl(225, 10%, 95%);
|
||||
--color-grey-225-10-97: hsl(225, 10%, 97%);
|
||||
|
||||
--color-blue-205-100-45: hsl(205, 100%, 45%);
|
||||
--color-blue-205-100-45-opacity-30: hsla(205, 100%, 45%, 30%);
|
||||
--color-blue-205-100-50: hsl(205, 100%, 50%);
|
||||
--color-blue-205-100-50-opacity-15: hsla(205, 100%, 50%, 15%);
|
||||
--color-blue-205-100-70: hsl(205, 100%, 75%);
|
||||
--color-blue-205-100-95: hsl(205, 100%, 95%);
|
||||
|
||||
--color-green-150-86-44: hsl(150, 86%, 44%);
|
||||
|
||||
--color-red-360-100-40: hsl(360, 100%, 40%);
|
||||
--color-red-360-100-45: hsl(360, 100%, 45%);
|
||||
--color-red-360-100-92: hsl(360, 100%, 92%);
|
||||
--color-red-360-100-97: hsl(360, 100%, 97%);
|
||||
|
||||
--color-white: hsl(0, 0%, 100%);
|
||||
--color-black: hsl(0, 0%, 0%);
|
||||
--color-black-opacity-10: hsla(0, 0%, 0%, 10%);
|
||||
--color-black-opacity-30: hsla(0, 0%, 0%, 30%);
|
||||
|
||||
--canvas-fill-color: var(--color-white);
|
||||
|
||||
--bendpoint-fill-color: var(--color-blue-205-100-45);
|
||||
--bendpoint-stroke-color: var(--canvas-fill-color);
|
||||
|
||||
--context-pad-entry-background-color: var(--color-white);
|
||||
--context-pad-entry-hover-background-color: var(--color-grey-225-10-95);
|
||||
|
||||
--element-dragger-color: var(--color-blue-205-100-50);
|
||||
--element-hover-outline-fill-color: var(--color-blue-205-100-45);
|
||||
--element-selected-outline-stroke-color: var(--color-blue-205-100-50);
|
||||
--element-selected-outline-secondary-stroke-color: var(--color-blue-205-100-70);
|
||||
|
||||
--lasso-fill-color: var(--color-blue-205-100-50-opacity-15);
|
||||
--lasso-stroke-color: var(--element-selected-outline-stroke-color);
|
||||
|
||||
--palette-entry-color: var(--color-grey-225-10-15);
|
||||
--palette-entry-hover-color: var(--color-blue-205-100-45);
|
||||
--palette-entry-selected-color: var(--color-blue-205-100-50);
|
||||
--palette-separator-color: var(--color-grey-225-10-75);
|
||||
--palette-toggle-hover-background-color: var(--color-grey-225-10-55);
|
||||
--palette-background-color: var(--color-grey-225-10-97);
|
||||
--palette-border-color: var(--color-grey-225-10-75);
|
||||
|
||||
--popup-font-size: 14px;
|
||||
--popup-header-entry-selected-color: var(--color-blue-205-100-50);
|
||||
--popup-header-font-weight: bolder;
|
||||
--popup-background-color: var(--color-white);
|
||||
--popup-border-color: transparent;
|
||||
--popup-shadow-color: var(--color-black-opacity-30);
|
||||
--popup-description-color: var(--color-grey-225-10-55);
|
||||
--popup-no-results-color: var(--color-grey-225-10-55);
|
||||
--popup-entry-title-color: var(--color-grey-225-10-55);
|
||||
--popup-entry-hover-color: var(--color-grey-225-10-95);
|
||||
--popup-search-border-color: var(--color-grey-225-10-75);
|
||||
--popup-search-focus-border-color: var(--color-blue-205-100-50);
|
||||
--popup-search-focus-background-color: var(--color-blue-205-100-95);
|
||||
|
||||
--resizer-fill-color: var(--color-blue-205-100-45);
|
||||
--resizer-stroke-color: var(--canvas-fill-color);
|
||||
|
||||
--search-container-background-color: var(--color-grey-225-10-97);
|
||||
--search-container-border-color: var(--color-blue-205-100-50);
|
||||
--search-container-box-shadow-color: var(--color-blue-205-100-95);
|
||||
--search-container-box-shadow-inset-color: var(--color-grey-225-10-80);
|
||||
--search-input-border-color: var(--color-grey-225-10-75);
|
||||
--search-result-border-color: var(--color-grey-225-10-75);
|
||||
--search-result-highlight-color: var(--color-black);
|
||||
--search-result-selected-color: var(--color-blue-205-100-45-opacity-30);
|
||||
|
||||
--shape-attach-allowed-stroke-color: var(--color-blue-205-100-50);
|
||||
--shape-connect-allowed-fill-color: var(--color-grey-225-10-97);
|
||||
--shape-drop-allowed-fill-color: var(--color-grey-225-10-97);
|
||||
--shape-drop-not-allowed-fill-color: var(--color-red-360-100-97);
|
||||
--shape-resize-preview-stroke-color: var(--color-blue-205-100-50);
|
||||
|
||||
--snap-line-stroke-color: var(--color-blue-205-100-45-opacity-30);
|
||||
|
||||
--space-tool-crosshair-stroke-color: var(--color-black);
|
||||
|
||||
--tooltip-error-background-color: var(--color-red-360-100-97);
|
||||
--tooltip-error-border-color: var(--color-red-360-100-45);
|
||||
--tooltip-error-color: var(--color-red-360-100-45);
|
||||
}
|
||||
|
||||
/**
|
||||
* outline styles
|
||||
*/
|
||||
|
||||
.djs-outline,
|
||||
.djs-selection-outline {
|
||||
fill: none;
|
||||
shape-rendering: geometricPrecision;
|
||||
stroke-width: 2px;
|
||||
}
|
||||
|
||||
.djs-outline {
|
||||
visibility: hidden;
|
||||
}
|
||||
|
||||
.djs-selection-outline {
|
||||
stroke: var(--element-selected-outline-stroke-color);
|
||||
}
|
||||
|
||||
.djs-element.selected .djs-outline {
|
||||
visibility: visible;
|
||||
|
||||
stroke: var(--element-selected-outline-stroke-color);
|
||||
}
|
||||
|
||||
.djs-multi-select .djs-element.selected .djs-outline {
|
||||
stroke: var(--element-selected-outline-secondary-stroke-color);
|
||||
}
|
||||
|
||||
.djs-shape.connect-ok .djs-visual > :nth-child(1) {
|
||||
fill: var(--shape-connect-allowed-fill-color) !important;
|
||||
}
|
||||
|
||||
.djs-shape.connect-not-ok .djs-visual > :nth-child(1),
|
||||
.djs-shape.drop-not-ok .djs-visual > :nth-child(1) {
|
||||
fill: var(--shape-drop-not-allowed-fill-color) !important;
|
||||
}
|
||||
|
||||
.djs-shape.new-parent .djs-visual > :nth-child(1) {
|
||||
fill: var(--shape-drop-allowed-fill-color) !important;
|
||||
}
|
||||
|
||||
svg.drop-not-ok {
|
||||
background: var(--shape-drop-not-allowed-fill-color) !important;
|
||||
}
|
||||
|
||||
svg.new-parent {
|
||||
background: var(--shape-drop-allowed-fill-color) !important;
|
||||
}
|
||||
|
||||
|
||||
/* Override move cursor during drop and connect */
|
||||
.drop-not-ok,
|
||||
.connect-not-ok,
|
||||
.drop-not-ok *,
|
||||
.connect-not-ok * {
|
||||
cursor: not-allowed !important;
|
||||
}
|
||||
|
||||
.drop-ok,
|
||||
.connect-ok,
|
||||
.drop-ok *,
|
||||
.connect-ok * {
|
||||
cursor: default !important;
|
||||
}
|
||||
|
||||
.djs-element.attach-ok .djs-visual > :nth-child(1) {
|
||||
stroke-width: 5px !important;
|
||||
stroke: var(--shape-attach-allowed-stroke-color) !important;
|
||||
}
|
||||
|
||||
.djs-frame.connect-not-ok .djs-visual > :nth-child(1),
|
||||
.djs-frame.drop-not-ok .djs-visual > :nth-child(1) {
|
||||
stroke-width: 3px !important;
|
||||
stroke: var(--shape-drop-not-allowed-fill-color) !important;
|
||||
fill: none !important;
|
||||
}
|
||||
|
||||
/**
|
||||
* Selection box style
|
||||
*
|
||||
*/
|
||||
.djs-lasso-overlay {
|
||||
fill: var(--lasso-fill-color);
|
||||
stroke: var(--lasso-stroke-color);
|
||||
stroke-width: 2px;
|
||||
shape-rendering: geometricPrecision;
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
/**
|
||||
* Resize styles
|
||||
*/
|
||||
.djs-resize-overlay {
|
||||
fill: none;
|
||||
|
||||
stroke-dasharray: 5 1 3 1;
|
||||
stroke: var(--shape-resize-preview-stroke-color);
|
||||
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.djs-resizer-hit {
|
||||
fill: none;
|
||||
pointer-events: all;
|
||||
}
|
||||
|
||||
.djs-resizer-visual {
|
||||
fill: var(--resizer-fill-color);
|
||||
stroke-width: 1px;
|
||||
stroke: var(--resizer-stroke-color);
|
||||
shape-rendering: geometricPrecision;
|
||||
}
|
||||
|
||||
.djs-resizer:hover .djs-resizer-visual {
|
||||
stroke: var(--resizer-stroke-color);
|
||||
stroke-opacity: 1;
|
||||
}
|
||||
|
||||
.djs-cursor-resize-ns,
|
||||
.djs-resizer-n,
|
||||
.djs-resizer-s {
|
||||
cursor: ns-resize;
|
||||
}
|
||||
|
||||
.djs-cursor-resize-ew,
|
||||
.djs-resizer-e,
|
||||
.djs-resizer-w {
|
||||
cursor: ew-resize;
|
||||
}
|
||||
|
||||
.djs-cursor-resize-nwse,
|
||||
.djs-resizer-nw,
|
||||
.djs-resizer-se {
|
||||
cursor: nwse-resize;
|
||||
}
|
||||
|
||||
.djs-cursor-resize-nesw,
|
||||
.djs-resizer-ne,
|
||||
.djs-resizer-sw {
|
||||
cursor: nesw-resize;
|
||||
}
|
||||
|
||||
.djs-shape.djs-resizing > .djs-outline {
|
||||
visibility: hidden !important;
|
||||
}
|
||||
|
||||
.djs-shape.djs-resizing > .djs-resizer {
|
||||
visibility: hidden;
|
||||
}
|
||||
|
||||
.djs-dragger > .djs-resizer {
|
||||
visibility: hidden;
|
||||
}
|
||||
|
||||
/**
|
||||
* drag styles
|
||||
*/
|
||||
.djs-dragger * {
|
||||
fill: none !important;
|
||||
stroke: var(--element-dragger-color) !important;
|
||||
}
|
||||
|
||||
.djs-dragger tspan,
|
||||
.djs-dragger text {
|
||||
fill: var(--element-dragger-color) !important;
|
||||
stroke: none !important;
|
||||
}
|
||||
|
||||
marker.djs-dragger circle,
|
||||
marker.djs-dragger path,
|
||||
marker.djs-dragger polygon,
|
||||
marker.djs-dragger polyline,
|
||||
marker.djs-dragger rect {
|
||||
fill: var(--element-dragger-color) !important;
|
||||
stroke: none !important;
|
||||
}
|
||||
|
||||
marker.djs-dragger text,
|
||||
marker.djs-dragger tspan {
|
||||
fill: none !important;
|
||||
stroke: var(--element-dragger-color) !important;
|
||||
}
|
||||
|
||||
.djs-dragging {
|
||||
opacity: 0.3;
|
||||
}
|
||||
|
||||
.djs-dragging,
|
||||
.djs-dragging > * {
|
||||
pointer-events: none !important;
|
||||
}
|
||||
|
||||
.djs-dragging .djs-context-pad,
|
||||
.djs-dragging .djs-outline {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
/**
|
||||
* no pointer events for visual
|
||||
*/
|
||||
.djs-visual,
|
||||
.djs-outline {
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.djs-element.attach-ok .djs-hit {
|
||||
stroke-width: 60px !important;
|
||||
}
|
||||
|
||||
/**
|
||||
* all pointer events for hit shape
|
||||
*/
|
||||
.djs-element > .djs-hit-all,
|
||||
.djs-element > .djs-hit-no-move {
|
||||
pointer-events: all;
|
||||
}
|
||||
|
||||
.djs-element > .djs-hit-stroke,
|
||||
.djs-element > .djs-hit-click-stroke {
|
||||
pointer-events: stroke;
|
||||
}
|
||||
|
||||
/**
|
||||
* shape / connection basic styles
|
||||
*/
|
||||
.djs-connection .djs-visual {
|
||||
stroke-width: 2px;
|
||||
fill: none;
|
||||
}
|
||||
|
||||
.djs-cursor-grab {
|
||||
cursor: -webkit-grab;
|
||||
cursor: -moz-grab;
|
||||
cursor: grab;
|
||||
}
|
||||
|
||||
.djs-cursor-grabbing {
|
||||
cursor: -webkit-grabbing;
|
||||
cursor: -moz-grabbing;
|
||||
cursor: grabbing;
|
||||
}
|
||||
|
||||
.djs-cursor-crosshair {
|
||||
cursor: crosshair;
|
||||
}
|
||||
|
||||
.djs-cursor-move {
|
||||
cursor: move;
|
||||
}
|
||||
|
||||
.djs-cursor-resize-ns {
|
||||
cursor: ns-resize;
|
||||
}
|
||||
|
||||
.djs-cursor-resize-ew {
|
||||
cursor: ew-resize;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* snapping
|
||||
*/
|
||||
.djs-snap-line {
|
||||
stroke: var(--snap-line-stroke-color);
|
||||
stroke-linecap: round;
|
||||
stroke-width: 2px;
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
/**
|
||||
* snapping
|
||||
*/
|
||||
.djs-crosshair {
|
||||
stroke: var(--space-tool-crosshair-stroke-color);
|
||||
stroke-linecap: round;
|
||||
stroke-width: 1px;
|
||||
pointer-events: none;
|
||||
shape-rendering: geometricPrecision;
|
||||
stroke-dasharray: 5, 5;
|
||||
}
|
||||
|
||||
/**
|
||||
* palette
|
||||
*/
|
||||
|
||||
.djs-palette {
|
||||
position: absolute;
|
||||
left: 20px;
|
||||
top: 20px;
|
||||
|
||||
box-sizing: border-box;
|
||||
width: 48px;
|
||||
}
|
||||
|
||||
.djs-palette .separator {
|
||||
margin: 5px;
|
||||
padding-top: 5px;
|
||||
|
||||
border: none;
|
||||
border-bottom: solid 1px var(--palette-separator-color);
|
||||
|
||||
clear: both;
|
||||
}
|
||||
|
||||
.djs-palette .entry:before {
|
||||
vertical-align: initial;
|
||||
}
|
||||
|
||||
.djs-palette .djs-palette-toggle {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.djs-palette .entry,
|
||||
.djs-palette .djs-palette-toggle {
|
||||
color: var(--palette-entry-color);
|
||||
font-size: 30px;
|
||||
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.djs-palette .entry {
|
||||
float: left;
|
||||
}
|
||||
|
||||
.djs-palette .entry img {
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.djs-palette .djs-palette-entries:after {
|
||||
content: '';
|
||||
display: table;
|
||||
clear: both;
|
||||
}
|
||||
|
||||
.djs-palette .djs-palette-toggle:hover {
|
||||
background: var(--palette-toggle-hover-background-color);
|
||||
}
|
||||
|
||||
.djs-palette .entry:hover {
|
||||
color: var(--palette-entry-hover-color);
|
||||
}
|
||||
|
||||
.djs-palette .highlighted-entry {
|
||||
color: var(--palette-entry-selected-color) !important;
|
||||
}
|
||||
|
||||
.djs-palette .entry,
|
||||
.djs-palette .djs-palette-toggle {
|
||||
width: 46px;
|
||||
height: 46px;
|
||||
line-height: 46px;
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
/**
|
||||
* Palette open / two-column layout is controlled via
|
||||
* classes on the palette. Events to hook into palette
|
||||
* changed life-cycle are available in addition.
|
||||
*/
|
||||
.djs-palette.two-column.open {
|
||||
width: 94px;
|
||||
}
|
||||
|
||||
.djs-palette:not(.open) .djs-palette-entries {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.djs-palette:not(.open) {
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.djs-palette.open .djs-palette-toggle {
|
||||
display: none;
|
||||
}
|
||||
|
||||
/**
|
||||
* context-pad
|
||||
*/
|
||||
.djs-overlay-context-pad {
|
||||
width: 72px;
|
||||
z-index: 100;
|
||||
}
|
||||
|
||||
.djs-context-pad {
|
||||
position: absolute;
|
||||
display: none;
|
||||
pointer-events: none;
|
||||
line-height: 1;
|
||||
}
|
||||
|
||||
.djs-context-pad .entry {
|
||||
width: 22px;
|
||||
height: 22px;
|
||||
text-align: center;
|
||||
display: inline-block;
|
||||
font-size: 22px;
|
||||
margin: 0 2px 2px 0;
|
||||
|
||||
border-radius: 3px;
|
||||
|
||||
cursor: default;
|
||||
|
||||
background-color: var(--context-pad-entry-background-color);
|
||||
box-shadow: 0 0 2px 1px var(--context-pad-entry-background-color);
|
||||
pointer-events: all;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.djs-context-pad .entry:hover {
|
||||
background: var(--context-pad-entry-hover-background-color);
|
||||
}
|
||||
|
||||
.djs-context-pad.open {
|
||||
display: block;
|
||||
}
|
||||
|
||||
/**
|
||||
* popup styles
|
||||
*/
|
||||
.djs-popup-backdrop {
|
||||
position: fixed;
|
||||
width: 100vw;
|
||||
height: 100vh;
|
||||
top: 0;
|
||||
left: 0;
|
||||
z-index: 200;
|
||||
line-height: 1;
|
||||
font-family: "IBM Plex Sans", sans-serif;
|
||||
}
|
||||
|
||||
.djs-popup {
|
||||
box-sizing: border-box;
|
||||
width: min-content;
|
||||
background: var(--popup-background-color);
|
||||
overflow: hidden;
|
||||
position: absolute;
|
||||
|
||||
box-shadow: 0px 2px 6px var(--popup-shadow-color);
|
||||
border: solid 1px var(--popup-border-color);
|
||||
min-width: 120px;
|
||||
outline: none;
|
||||
font-size: var(--popup-font-size);
|
||||
}
|
||||
|
||||
.djs-popup-search input {
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
font-size: var(--popup-font-size);
|
||||
padding: 3px 6px;
|
||||
border-radius: 2px;
|
||||
border: solid 1px var(--popup-search-border-color);
|
||||
line-height: 21px;
|
||||
}
|
||||
|
||||
.djs-popup-search input:focus {
|
||||
background-color: var(--popup-search-focus-background-color);
|
||||
border: solid 1px var(--popup-search-focus-border-color);
|
||||
outline: none;
|
||||
}
|
||||
|
||||
.djs-popup-header {
|
||||
display: flex;
|
||||
align-items: stretch;
|
||||
line-height: 20px;
|
||||
margin: 10px 12px 10px 12px;
|
||||
}
|
||||
|
||||
.djs-popup-header .entry {
|
||||
border-radius: 2px;
|
||||
}
|
||||
|
||||
.djs-popup-header .entry.active {
|
||||
color: var(--popup-header-entry-selected-color);
|
||||
}
|
||||
|
||||
.djs-popup-header .entry.disabled {
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
.djs-popup-search {
|
||||
margin: 10px 12px;
|
||||
}
|
||||
|
||||
.djs-popup-title {
|
||||
font-size: var(--popup-font-size);
|
||||
font-weight: var(--popup-header-font-weight);
|
||||
flex: 1;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.djs-popup-search {
|
||||
position: relative;
|
||||
width: auto;
|
||||
}
|
||||
|
||||
.djs-popup-search-icon {
|
||||
position: absolute;
|
||||
left: 8px;
|
||||
top: 7px;
|
||||
}
|
||||
|
||||
.djs-popup-search input {
|
||||
padding-left: 25px;
|
||||
}
|
||||
|
||||
.djs-popup-results {
|
||||
margin: 7px 3px 7px 12px;
|
||||
list-style: none;
|
||||
max-height: 280px;
|
||||
overflow: auto;
|
||||
padding-right: 9px;
|
||||
}
|
||||
|
||||
.djs-popup-group {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.djs-popup-body .entry,
|
||||
.djs-popup-body .entry-header {
|
||||
padding: 5px 7px;
|
||||
cursor: default;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.djs-popup-body .entry-header {
|
||||
font-weight: var(--popup-header-font-weight);
|
||||
color: var(--popup-entry-title-color);
|
||||
padding-left: 0;
|
||||
}
|
||||
|
||||
.djs-popup [class*="icon"] .djs-popup-label,
|
||||
.djs-popup-label:not(:first-child) {
|
||||
margin-left: .5em;
|
||||
}
|
||||
|
||||
.djs-popup [class*="icon"]:before,
|
||||
.djs-popup-entry-icon {
|
||||
width: 1em;
|
||||
height: 1em;
|
||||
display: inline-block;
|
||||
font-size: 1.4em;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.djs-popup-body .entry-header:not(:first-child) {
|
||||
margin-top: 8px;
|
||||
margin-bottom: 2px;
|
||||
}
|
||||
|
||||
.djs-popup-body .entry {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
align-items: stretch;
|
||||
height: min-content;
|
||||
}
|
||||
|
||||
.djs-popup .entry.selected {
|
||||
background-color: var(--popup-entry-hover-color);
|
||||
}
|
||||
|
||||
.djs-popup-body .entry:not(:first-child) {
|
||||
margin-top: 2px;
|
||||
}
|
||||
|
||||
.djs-popup-entry-content {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
flex: 1;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.djs-popup-entry-description {
|
||||
color: var(--popup-description-color);
|
||||
}
|
||||
|
||||
.djs-popup-label,
|
||||
.djs-popup-entry-description {
|
||||
line-height: 1.4em;
|
||||
}
|
||||
|
||||
.djs-popup-title,
|
||||
.djs-popup-label,
|
||||
.djs-popup-entry-description,
|
||||
.djs-popup .entry-header {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.djs-popup-entry-name {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.entry-content {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
flex: 1;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.djs-popup-body {
|
||||
flex-direction: column;
|
||||
width: auto;
|
||||
}
|
||||
|
||||
.djs-popup *::-webkit-scrollbar {
|
||||
width: 6px;
|
||||
}
|
||||
|
||||
.djs-popup *::-webkit-scrollbar-thumb {
|
||||
border-radius: 3px;
|
||||
background-color: rgba(0, 0, 0, 0.2);
|
||||
}
|
||||
|
||||
.djs-popup *::-webkit-scrollbar-track {
|
||||
box-shadow: none;
|
||||
background: transparent;
|
||||
margin: 0;
|
||||
padding: 5px;
|
||||
}
|
||||
|
||||
.djs-popup-no-results {
|
||||
padding: 0 12px 12px 12px;
|
||||
color: var(--popup-no-results-color);
|
||||
}
|
||||
|
||||
.djs-popup-entry-docs {
|
||||
flex: 0;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
padding-left: 5px;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.djs-popup-body .entry:hover .djs-popup-entry-docs {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.djs-popup-entry-docs svg {
|
||||
vertical-align: middle;
|
||||
margin: auto 2px auto 5px;
|
||||
}
|
||||
|
||||
/**
|
||||
* palette styles
|
||||
*/
|
||||
.djs-palette {
|
||||
background: var(--palette-background-color);
|
||||
border: solid 1px var(--palette-border-color);
|
||||
border-radius: 2px;
|
||||
}
|
||||
|
||||
/**
|
||||
* touch
|
||||
*/
|
||||
|
||||
.djs-shape,
|
||||
.djs-connection {
|
||||
touch-action: none;
|
||||
}
|
||||
|
||||
.djs-segment-dragger,
|
||||
.djs-bendpoint {
|
||||
display: none;
|
||||
}
|
||||
|
||||
/**
|
||||
* bendpoints
|
||||
*/
|
||||
.djs-segment-dragger .djs-visual {
|
||||
display: none;
|
||||
|
||||
fill: var(--bendpoint-fill-color);
|
||||
stroke: var(--bendpoint-stroke-color);
|
||||
stroke-width: 1px;
|
||||
stroke-opacity: 1;
|
||||
}
|
||||
|
||||
.djs-segment-dragger:hover .djs-visual {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.djs-bendpoint .djs-visual {
|
||||
fill: var(--bendpoint-fill-color);
|
||||
stroke: var(--bendpoint-stroke-color);
|
||||
stroke-width: 1px;
|
||||
}
|
||||
|
||||
.djs-segment-dragger:hover,
|
||||
.djs-bendpoints.hover .djs-segment-dragger,
|
||||
.djs-bendpoints.selected .djs-segment-dragger,
|
||||
.djs-bendpoint:hover,
|
||||
.djs-bendpoints.hover .djs-bendpoint,
|
||||
.djs-bendpoints.selected .djs-bendpoint {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.djs-drag-active .djs-bendpoints * {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.djs-bendpoints:not(.hover) .floating {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.djs-segment-dragger:hover .djs-visual,
|
||||
.djs-segment-dragger.djs-dragging .djs-visual,
|
||||
.djs-bendpoint:hover .djs-visual,
|
||||
.djs-bendpoint.floating .djs-visual {
|
||||
fill: var(--bendpoint-fill-color);
|
||||
stroke: var(--bendpoint-stroke-color);
|
||||
stroke-opacity: 1;
|
||||
}
|
||||
|
||||
.djs-bendpoint.floating .djs-hit {
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.djs-segment-dragger .djs-hit,
|
||||
.djs-bendpoint .djs-hit {
|
||||
fill: none;
|
||||
pointer-events: all;
|
||||
}
|
||||
|
||||
.djs-segment-dragger.horizontal .djs-hit {
|
||||
cursor: ns-resize;
|
||||
}
|
||||
|
||||
.djs-segment-dragger.vertical .djs-hit {
|
||||
cursor: ew-resize;
|
||||
}
|
||||
|
||||
.djs-segment-dragger.djs-dragging .djs-hit {
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
.djs-updating,
|
||||
.djs-updating > * {
|
||||
pointer-events: none !important;
|
||||
}
|
||||
|
||||
.djs-updating .djs-context-pad,
|
||||
.djs-updating .djs-outline,
|
||||
.djs-updating .djs-bendpoint,
|
||||
.djs-multi-select .djs-bendpoint,
|
||||
.djs-multi-select .djs-segment-dragger,
|
||||
.connect-ok .djs-bendpoint,
|
||||
.connect-not-ok .djs-bendpoint,
|
||||
.drop-ok .djs-bendpoint,
|
||||
.drop-not-ok .djs-bendpoint {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.djs-segment-dragger.djs-dragging,
|
||||
.djs-bendpoint.djs-dragging {
|
||||
display: block;
|
||||
opacity: 1.0;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* tooltips
|
||||
*/
|
||||
.djs-tooltip-error {
|
||||
width: 160px;
|
||||
padding: 6px;
|
||||
|
||||
background: var(--tooltip-error-background-color);
|
||||
border: solid 1px var(--tooltip-error-border-color);
|
||||
border-radius: 2px;
|
||||
color: var(--tooltip-error-color);
|
||||
font-size: 12px;
|
||||
line-height: 16px;
|
||||
|
||||
opacity: 0.75;
|
||||
}
|
||||
|
||||
.djs-tooltip-error:hover {
|
||||
opacity: 1;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* search pad
|
||||
*/
|
||||
.djs-search-container {
|
||||
position: absolute;
|
||||
top: 20px;
|
||||
left: 0;
|
||||
right: 0;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
|
||||
width: 25%;
|
||||
min-width: 300px;
|
||||
max-width: 400px;
|
||||
z-index: 10;
|
||||
|
||||
font-size: 1.05em;
|
||||
opacity: 0.9;
|
||||
background: var(--search-container-background-color);
|
||||
border: solid 1px var(--search-container-border-color);
|
||||
border-radius: 2px;
|
||||
box-shadow: 0 0 0 2px var(--search-container-box-shadow-color), 0 0 0 1px var(--search-container-box-shadow-inset-color) inset;
|
||||
}
|
||||
|
||||
.djs-search-container:not(.open) {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.djs-search-input input {
|
||||
font-size: 1.05em;
|
||||
width: 100%;
|
||||
padding: 6px 10px;
|
||||
border: 1px solid var(--search-input-border-color);
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.djs-search-input input:focus {
|
||||
outline: none;
|
||||
border-color: var(--search-input-border-color);
|
||||
}
|
||||
|
||||
.djs-search-results {
|
||||
position: relative;
|
||||
overflow-y: auto;
|
||||
max-height: 200px;
|
||||
}
|
||||
|
||||
.djs-search-results:hover {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.djs-search-result {
|
||||
width: 100%;
|
||||
padding: 6px 10px;
|
||||
background: white;
|
||||
border-bottom: solid 1px var(--search-result-border-color);
|
||||
border-radius: 1px;
|
||||
}
|
||||
|
||||
.djs-search-highlight {
|
||||
color: var(--search-result-highlight-color);
|
||||
}
|
||||
|
||||
.djs-search-result-primary {
|
||||
margin: 0 0 10px;
|
||||
}
|
||||
|
||||
.djs-search-result-secondary {
|
||||
font-family: monospace;
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.djs-search-result:hover {
|
||||
background: var(--search-result-selected-color);
|
||||
}
|
||||
|
||||
.djs-search-result-selected {
|
||||
background: var(--search-result-selected-color);
|
||||
}
|
||||
|
||||
.djs-search-result-selected:hover {
|
||||
background: var(--search-result-selected-color);
|
||||
}
|
||||
|
||||
.djs-search-overlay {
|
||||
background: var(--search-result-selected-color);
|
||||
}
|
||||
|
||||
/**
|
||||
* hidden styles
|
||||
*/
|
||||
.djs-element-hidden,
|
||||
.djs-element-hidden .djs-hit,
|
||||
.djs-element-hidden .djs-outline,
|
||||
.djs-label-hidden .djs-label {
|
||||
display: none !important;
|
||||
}
|
||||
|
||||
.djs-element .djs-hit-stroke,
|
||||
.djs-element .djs-hit-click-stroke,
|
||||
.djs-element .djs-hit-all {
|
||||
cursor: move;
|
||||
}
|
||||
Binary file not shown.
File diff suppressed because one or more lines are too long
|
Before Width: | Height: | Size: 130 KiB |
Binary file not shown.
Binary file not shown.
Binary file not shown.
10486
server/src/main/resources/static/gitalk/gitalk-component.js
Normal file
10486
server/src/main/resources/static/gitalk/gitalk-component.js
Normal file
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
1250
server/src/main/resources/static/gitalk/gitalk.css
Normal file
1250
server/src/main/resources/static/gitalk/gitalk.css
Normal file
File diff suppressed because it is too large
Load Diff
1
server/src/main/resources/static/gitalk/gitalk.css.map
Normal file
1
server/src/main/resources/static/gitalk/gitalk.css.map
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"sources":[],"names":[],"mappings":"","file":"gitalk.css","sourceRoot":""}
|
||||
14001
server/src/main/resources/static/gitalk/gitalk.js
Normal file
14001
server/src/main/resources/static/gitalk/gitalk.js
Normal file
File diff suppressed because it is too large
Load Diff
1
server/src/main/resources/static/gitalk/gitalk.js.map
Normal file
1
server/src/main/resources/static/gitalk/gitalk.js.map
Normal file
File diff suppressed because one or more lines are too long
35
server/src/main/resources/static/gitalk/gitalk.min.js
vendored
Normal file
35
server/src/main/resources/static/gitalk/gitalk.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
Binary file not shown.
|
Before Width: | Height: | Size: 211 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 130 KiB |
@@ -1,4 +1,4 @@
|
||||
<!DOCTYPE html>
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
|
||||
<head>
|
||||
@@ -45,8 +45,6 @@
|
||||
</div>
|
||||
<div id="zoomSelect" class="select-icon" title="缩放比例">
|
||||
<select id="zoomValue">
|
||||
<option value="width">适合页宽</option>
|
||||
<option value="4.0">400%</option>
|
||||
<option value="3.0">300%</option>
|
||||
<option value="2.0">200%</option>
|
||||
<option value="1.5">150%</option>
|
||||
|
||||
@@ -53,7 +53,6 @@ window.onresize = function() {
|
||||
} ();
|
||||
};
|
||||
|
||||
// 手机端,隐藏缩放比例选择框,打开文件和打印按钮
|
||||
if (this.isMobile()) {
|
||||
if (document.getElementById("zoomSelect")) document.getElementById("zoomSelect").style.display = "none";
|
||||
if (document.getElementById("openFile")) document.getElementById("openFile").style.display = "none";
|
||||
@@ -62,12 +61,11 @@ if (this.isMobile()) {
|
||||
if (document.getElementById("separator2")) document.getElementById("separator2").style.display = "none";
|
||||
}
|
||||
|
||||
// 判断手机端还是PC端
|
||||
function isMobile() {
|
||||
var flag = navigator.userAgent.match(/(phone|pad|pod|iPhone|iPod|ios|iPad|Android|Mobile|BlackBerry|IEMobile|MQQBrowser|JUC|Fennec|wOSBrowser|BrowserNG|WebOS|Symbian|Windows Phone)/i);
|
||||
return flag;
|
||||
}
|
||||
// 判断是否IE浏览器
|
||||
|
||||
function isIE() {
|
||||
var navigator = window.navigator.userAgent;
|
||||
if (navigator.indexOf("MSIE") > 0 || navigator.indexOf("Trident") > 0) {
|
||||
@@ -98,34 +96,9 @@ data: function data() {
|
||||
};
|
||||
}
|
||||
|
||||
this.pageZoomScale = "1.0";
|
||||
cnofd["setScaleValue"](this.pageZoomScale);
|
||||
var scale = this.getQueryVariable("scale");
|
||||
if (scale && (scale == "width" || Number(scale))) {
|
||||
this.pageZoomScale = scale;
|
||||
cnofd["setScaleValue"](scale);
|
||||
}
|
||||
|
||||
var file = this.getQueryVariable("file");
|
||||
file = decodeURIComponent(file);
|
||||
if (file) this.loadOfdFile(file);
|
||||
|
||||
if (scale && (scale == "width" || Number(scale))) {
|
||||
var selectZoom = document.getElementById("zoomValue");
|
||||
|
||||
selectZoom.selectedIndex = -1;
|
||||
if (this.pageZoomScale == "width") {
|
||||
selectZoom.selectedIndex = 0;
|
||||
} else {
|
||||
for (var i = 1; i < selectZoom.length; i++) {
|
||||
if (Math.abs(this.pageZoomScale - selectZoom.options[i].value) < 0.01) {
|
||||
selectZoom.selectedIndex = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function getQueryVariable(variable) {
|
||||
var query = window.location.search.substring(1);
|
||||
var vars = query.split("&");
|
||||
@@ -152,7 +125,8 @@ function loadOfdFile(ofdFile) {
|
||||
that.ofdBase64 = base64String;
|
||||
}
|
||||
});
|
||||
this.getOfdDocument(ofdFile, this.screenWidth, this.pageZoomScale);
|
||||
ofdFile = ofdFile = decodeURIComponent(ofdFile);
|
||||
this.getOfdDocument(ofdFile, this.screenWidth);
|
||||
|
||||
setPageInfo();
|
||||
}
|
||||
@@ -196,12 +170,10 @@ function fileChanged() {
|
||||
return;
|
||||
}
|
||||
|
||||
// 新打开OFD文件时,还原成页面实际尺寸显示
|
||||
//Object(cnofd["setScaleValue"])(1.0);
|
||||
Object(cnofd["setScaleValue"])(this.pageZoomScale);
|
||||
Object(cnofd["setScaleValue"])(1.0);
|
||||
var selectZoom = document.getElementById("zoomValue");
|
||||
if (selectZoom)
|
||||
selectZoom.value = this.pageZoomScale;
|
||||
selectZoom.value = "1.0";
|
||||
|
||||
var that = this;
|
||||
var reader = new FileReader();
|
||||
@@ -211,11 +183,10 @@ function fileChanged() {
|
||||
that.ofdBase64 = e.target.result.split(",")[1];
|
||||
};
|
||||
|
||||
this.getOfdDocument(this.file, this.screenWidth, this.pageZoomScale);
|
||||
//$("#file")[0].value = null;
|
||||
this.getOfdDocument(this.file, this.screenWidth);
|
||||
}
|
||||
|
||||
function getOfdDocument(file, screenWidth, pageZoomScale) {
|
||||
function getOfdDocument(file, screenWidth) {
|
||||
var that = this;
|
||||
|
||||
$("#loading").show();
|
||||
@@ -228,18 +199,14 @@ function getOfdDocument(file, screenWidth, pageZoomScale) {
|
||||
that.ofdDoc = res;
|
||||
that.pageIndex = 1;
|
||||
that.pageCount = res.pageCount;
|
||||
if (pageZoomScale == "width") {
|
||||
var divs = Object(cnofd["ofdRender"])(res, screenWidth);
|
||||
that.displayOfdDiv(divs);
|
||||
} else {
|
||||
var divs = Object(cnofd["ofdRenderByScale"])(res, screenWidth, pageZoomScale);
|
||||
that.displayOfdDiv(divs);
|
||||
}
|
||||
var divs = Object(cnofd["ofdRender"])(res, screenWidth);
|
||||
that.displayOfdDiv(divs);
|
||||
$("#loading").hide();
|
||||
},
|
||||
fail: function fail(error) {
|
||||
$("#loading").hide();
|
||||
alert("OFD打开失败", error, {
|
||||
|
||||
that.$alert("OFD打开失败", error, {
|
||||
confirmButtonText: "确定",
|
||||
callback: function callback(action) {
|
||||
this.$message({
|
||||
@@ -275,7 +242,7 @@ function displayOfdDiv(divs) {
|
||||
|
||||
function zoomIn() {
|
||||
var selectZoom = document.getElementById("zoomValue");
|
||||
if (selectZoom.selectedIndex > 1) {
|
||||
if (selectZoom.selectedIndex > 0) {
|
||||
selectZoom.selectedIndex = selectZoom.selectedIndex - 1;
|
||||
|
||||
Object(cnofd["setScaleValue"])(selectZoom.options[selectZoom.selectedIndex].value);
|
||||
@@ -292,7 +259,6 @@ function zoomOut() {
|
||||
var selectZoom = document.getElementById("zoomValue");
|
||||
if (selectZoom.selectedIndex < selectZoom.length-1) {
|
||||
selectZoom.selectedIndex = selectZoom.selectedIndex + 1;
|
||||
if (selectZoom.selectedIndex == 0) selectZoom.selectedIndex = 1;
|
||||
|
||||
Object(cnofd["setScaleValue"])(selectZoom.options[selectZoom.selectedIndex].value);
|
||||
var divs = Object(cnofd["ofdRenderByScale"])(this.ofdDoc);
|
||||
@@ -306,23 +272,13 @@ function zoomOut() {
|
||||
|
||||
function zoomChange() {
|
||||
var selectZoom = document.getElementById("zoomValue");
|
||||
if (selectZoom.options[selectZoom.selectedIndex].value == "width") {
|
||||
Object(cnofd["setScaleValue"])(selectZoom.options[selectZoom.selectedIndex].value);
|
||||
var divs = Object(cnofd["ofdRender"])(this.ofdDoc, this.screenWidth);
|
||||
if (divs) {
|
||||
this.displayOfdDiv(divs);
|
||||
} else {
|
||||
this.getOfdDocument(this.file, this.screenWidth);
|
||||
}
|
||||
Object(cnofd["setScaleValue"])(selectZoom.options[selectZoom.selectedIndex].value);
|
||||
var divs = Object(cnofd["ofdRenderByScale"])(this.ofdDoc);
|
||||
if (divs) {
|
||||
this.displayOfdDiv(divs);
|
||||
} else {
|
||||
Object(cnofd["setScaleValue"])(selectZoom.options[selectZoom.selectedIndex].value);
|
||||
var divs = Object(cnofd["ofdRenderByScale"])(this.ofdDoc);
|
||||
if (divs) {
|
||||
this.displayOfdDiv(divs);
|
||||
} else {
|
||||
this.getOfdDocument(this.file, this.screenWidth);
|
||||
}
|
||||
}
|
||||
this.getOfdDocument(this.file, this.screenWidth);
|
||||
}
|
||||
}
|
||||
|
||||
function scrool() {
|
||||
@@ -406,7 +362,7 @@ function print() {
|
||||
if (list.length > 0) {
|
||||
if (!isIE()) {
|
||||
var mywindow = window.open("打印窗口", "_blank");
|
||||
mywindow.document.write('<!DOCTYPE html><html><head>'
|
||||
mywindow.document.write('<!DOCTYPE html><html><head>'
|
||||
+'<style media="print">.page-break { page-break-inside: avoid; page-break-after: always; }</style>'
|
||||
+'</head><body></body</html>');
|
||||
var documentBody = mywindow.document.body;
|
||||
@@ -443,9 +399,7 @@ function print() {
|
||||
}
|
||||
}
|
||||
|
||||
// IE浏览器,在iframe里调用打印
|
||||
function printIE(printhtml) {
|
||||
//新建一个iframe
|
||||
var iframe = document.createElement("iframe");
|
||||
iframe.id = "printf";
|
||||
iframe.style.width = "0";
|
||||
@@ -453,7 +407,6 @@ function printIE(printhtml) {
|
||||
iframe.style.height = "0";
|
||||
iframe.style.border = "none";
|
||||
|
||||
//将iframe插入到printBody里
|
||||
document.body.appendChild(iframe);
|
||||
|
||||
setTimeout(function () {
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,44 +0,0 @@
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
|
||||
<#include "*/commonHeader.ftl">
|
||||
<style>
|
||||
html, body, #diagram {
|
||||
height: 100%
|
||||
}
|
||||
</style>
|
||||
<title>kkFileView Bpmn</title>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h2>kkFileView Bpmn : ${fileName}</h2>
|
||||
|
||||
<div id="diagram"></div>
|
||||
|
||||
<!-- required modeler styles -->
|
||||
<link rel="stylesheet" href="bpmn/diagram-js.css">
|
||||
<link rel="stylesheet" href="bpmn/bpmn-js.css">
|
||||
<link rel="stylesheet" href="bpmn/css/bpmn.css">
|
||||
|
||||
<!-- modeler distro -->
|
||||
<script src="bpmn/bpmn-modeler.development.js"></script>
|
||||
<script src="js/jquery-3.6.1.min.js"></script>
|
||||
|
||||
<!-- app -->
|
||||
<script>
|
||||
|
||||
const viewer = new BpmnJS({
|
||||
container: '#diagram'
|
||||
});
|
||||
|
||||
async function showDiagram(diagramXML) {
|
||||
await viewer.importXML(diagramXML);
|
||||
}
|
||||
// load + show diagram
|
||||
$.get('${currentUrl}', showDiagram, 'text');
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
94
server/src/main/resources/web/comment.ftl
Normal file
94
server/src/main/resources/web/comment.ftl
Normal file
@@ -0,0 +1,94 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8"/>
|
||||
<meta name="viewport" content="width=device-width, user-scalable=yes, initial-scale=1.0"/>
|
||||
<title>kkFileView相关交流</title>
|
||||
<link rel="icon" href="./favicon.ico" type="image/x-icon">
|
||||
<link rel="stylesheet" href="css/viewer.min.css"/>
|
||||
<link rel="stylesheet" href="css/loading.css"/>
|
||||
<link rel="stylesheet" href="bootstrap/css/bootstrap.min.css"/>
|
||||
<link rel="stylesheet" href="bootstrap/css/bootstrap-theme.min.css"/>
|
||||
<link rel="stylesheet" href="css/theme.css"/>
|
||||
<link rel="stylesheet" href="gitalk/gitalk.css"/>
|
||||
<script type="text/javascript" src="js/jquery-3.6.1.min.js"></script>
|
||||
<script type="text/javascript" src="js/jquery.form.min.js"></script>
|
||||
<script type="text/javascript" src="bootstrap/js/bootstrap.min.js"></script>
|
||||
<script type="text/javascript" src="gitalk/gitalk.min.js"></script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<!-- Fixed navbar -->
|
||||
<nav class="navbar navbar-inverse navbar-fixed-top">
|
||||
<div class="container">
|
||||
<div class="navbar-header">
|
||||
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
|
||||
<span class="sr-only">Toggle navigation</span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
</button>
|
||||
<a class="navbar-brand" href="https://kkview.cn" target='_blank'>kkFileView</a>
|
||||
</div>
|
||||
<div id="navbar" class="navbar-collapse collapse">
|
||||
<ul class="nav navbar-nav">
|
||||
<li><a href="./index">首页</a></li>
|
||||
<li><a href="./record">版本发布记录</a></li>
|
||||
<li class="active"><a href="./comment">相关交流</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
<div class="container theme-showcase" role="main">
|
||||
<#-- 相关交流 -->
|
||||
<div class="page-header">
|
||||
<h1>相关交流</h1>
|
||||
</div>
|
||||
|
||||
<div class="panel-body">
|
||||
<div id="comments"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="loading_container">
|
||||
<div class="spinner">
|
||||
<div class="spinner-container container1">
|
||||
<div class="circle1"></div>
|
||||
<div class="circle2"></div>
|
||||
<div class="circle3"></div>
|
||||
<div class="circle4"></div>
|
||||
</div>
|
||||
<div class="spinner-container container2">
|
||||
<div class="circle1"></div>
|
||||
<div class="circle2"></div>
|
||||
<div class="circle3"></div>
|
||||
<div class="circle4"></div>
|
||||
</div>
|
||||
<div class="spinner-container container3">
|
||||
<div class="circle1"></div>
|
||||
<div class="circle2"></div>
|
||||
<div class="circle3"></div>
|
||||
<div class="circle4"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
$(function () {
|
||||
var gitalk = new Gitalk({
|
||||
clientID: '525d7f16e17aab08cef5',
|
||||
clientSecret: 'd1154e3aee5c8f1cbdc918b5c97a4f4157e0bfd9',
|
||||
repo: 'kkFileView',
|
||||
owner: 'kekingcn',
|
||||
admin: ['kekingcn,klboke,gitchenjh'],
|
||||
language: 'zh-CN',
|
||||
id: location.pathname,
|
||||
distractionFreeMode: false
|
||||
})
|
||||
gitalk.render((document.getElementById('comments')))
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -18,7 +18,7 @@
|
||||
<script type="text/javascript" src="bootstrap-table/bootstrap-table.min.js"></script>
|
||||
<script type="text/javascript" src="js/base64.min.js"></script>
|
||||
<style>
|
||||
.alert {
|
||||
.alert{
|
||||
width: 50%;
|
||||
}
|
||||
</style>
|
||||
@@ -26,93 +26,74 @@
|
||||
|
||||
<body>
|
||||
|
||||
<!-- Fixed navbar -->
|
||||
<nav class="navbar navbar-inverse navbar-fixed-top">
|
||||
<div class="container">
|
||||
<!-- Fixed navbar -->
|
||||
<nav class="navbar navbar-inverse navbar-fixed-top">
|
||||
<div class="container">
|
||||
<div class="navbar-header">
|
||||
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar"
|
||||
aria-expanded="false" aria-controls="navbar">
|
||||
<span class="sr-only">Toggle navigation</span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
</button>
|
||||
<a class="navbar-brand" href="https://kkview.cn" target='_blank'>kkFileView</a>
|
||||
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
|
||||
<span class="sr-only">Toggle navigation</span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
</button>
|
||||
<a class="navbar-brand" href="https://kkview.cn" target='_blank'>kkFileView</a>
|
||||
</div>
|
||||
<div id="navbar" class="navbar-collapse collapse">
|
||||
<ul class="nav navbar-nav">
|
||||
<li class="active"><a href="./index">首页</a></li>
|
||||
<li><a href="./integrated">接入说明</a></li>
|
||||
<li><a href="./record">版本发布记录</a></li>
|
||||
<li><a href="./sponsor">赞助开源</a></li>
|
||||
</ul>
|
||||
<ul class="nav navbar-nav">
|
||||
<li class="active"><a href="./index">首页</a></li>
|
||||
<li><a href="./record">版本发布记录</a></li>
|
||||
<li><a href="./comment">相关交流</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
<div class="container theme-showcase" role="main">
|
||||
<#-- 接入说明 -->
|
||||
<div class="page-header">
|
||||
<h1>支持的文件类型</h1>
|
||||
我们一直在扩展支持的文件类型,不断优化预览的效果,如果您有什么建议,欢迎在kk开源社区留意反馈:<a target='_blank' href="https://t.zsxq.com/09ZHSXbsQ">https://t.zsxq.com/09ZHSXbsQ</a>。
|
||||
</div>
|
||||
<div >
|
||||
<ol>
|
||||
<li>支持 doc, docx, xls, xlsx, xlsm, ppt, pptx, csv, tsv, dotm, xlt, xltm, dot, dotx,xlam, xla 等 Office 办公文档</li>
|
||||
<li>支持 wps, dps, et, ett, wpt 等国产 WPS Office 办公文档</li>
|
||||
<li>支持 odt, ods, ots, odp, otp, six, ott, fodt, fods 等OpenOffice、LibreOffice 办公文档</li>
|
||||
<li>支持 vsd, vsdx 等 Visio 流程图文件</li>
|
||||
<li>支持 wmf, emf 等 Windows 系统图像文件</li>
|
||||
<li>支持 psd 等 Photoshop 软件模型文件</li>
|
||||
<li>支持 pdf ,ofd, rtf 等文档</li>
|
||||
<li>支持 xmind 软件模型文件</li>
|
||||
<li>支持 bpmn 工作流文件</li>
|
||||
<li>支持 eml 邮件文件</li>
|
||||
<li>支持 epub 图书文档</li>
|
||||
<li>支持 obj, 3ds, stl, ply, gltf, glb, off, 3dm, fbx, dae, wrl, 3mf, ifc, brep, step, iges, fcstd, bim 等 3D 模型文件</li>
|
||||
<li>支持 dwg, dxf 等 CAD 模型文件</li>
|
||||
<li>支持 txt, xml(渲染), md(渲染), java, php, py, js, css 等所有纯文本</li>
|
||||
<li>支持 zip, rar, jar, tar, gzip, 7z 等压缩包</li>
|
||||
<li>支持 jpg, jpeg, png, gif, bmp, ico, jfif, webp 等图片预览(翻转,缩放,镜像)</li>
|
||||
<li>支持 tif, tiff 图信息模型文件</li>
|
||||
<li>支持 tga 图像格式文件</li>
|
||||
<li>支持 svg 矢量图像格式文件</li>
|
||||
<li>支持 mp3,wav,mp4,flv 等音视频格式文件</li>
|
||||
<li>支持 avi,mov,rm,webm,ts,rm,mkv,mpeg,ogg,mpg,rmvb,wmv,3gp,ts,swf 等视频格式转码预览</li>
|
||||
</ol>
|
||||
</div>
|
||||
<#-- 输入下载地址预览文件 -->
|
||||
<div class="panel panel-success">
|
||||
<div class="container theme-showcase" role="main">
|
||||
<#-- 接入说明 -->
|
||||
<div class="page-header">
|
||||
<h1>接入说明</h1>
|
||||
</div>
|
||||
<div class="well">
|
||||
<div style="font-size: 16px;">
|
||||
如果你的项目需要接入文件预览项目,达到对docx、excel、ppt、jpg等文件的预览效果,那么通过在你的项目中加入下面的代码就可以成功实现:
|
||||
<p style="background-color: #2f332a;color: #cccccc;font-size: 14px;padding:10px;margin-top:10px;">
|
||||
var url = 'http://127.0.0.1:8080/file/test.txt'; //要预览文件的访问地址 <br>
|
||||
window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(base64Encode(url)));
|
||||
</p>
|
||||
</div>
|
||||
<div style="font-size: 16px;">
|
||||
新增多图片同时预览功能,接口如下:
|
||||
<p style="background-color: #2f332a;color: #cccccc;font-size: 14px;padding:10px;margin-top:10px;">
|
||||
var fileUrl =url1+'|'+url2;//多url使用'|'字符隔开 <br>
|
||||
window.open('http://127.0.0.1:8012/picturesPreview?urls='+encodeURIComponent(base64Encode(fileUrl)));
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<#-- 输入下载地址预览文件 -->
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">输入下载地址预览</h3>
|
||||
<h3 class="panel-title">输入下载地址预览文件</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<form>
|
||||
<div class="row">
|
||||
<div class="col-md-10">
|
||||
<div class="form-group">
|
||||
<input type="url" class="form-control" id="_url" placeholder="请输入预览文件 url">
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<button id="previewByUrl" type="button" class="btn btn-success">预览</button>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label>文件下载地址</label>
|
||||
<input type="url" class="form-control" id="_url" placeholder="请输入下载地址">
|
||||
</div>
|
||||
|
||||
<div class="alert alert-danger alert-dismissable hide" role="alert" id="previewCheckAlert">
|
||||
<button type="button" class="close" data-dismiss="alert" aria-label="Close">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
<strong>请输入正确的url</strong>
|
||||
</div>
|
||||
|
||||
<button id="previewByUrl" type="button" class="btn btn-success">预览</button>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<#-- 预览测试 -->
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">上传本地文件预览</h3>
|
||||
<h3 class="panel-title">预览测试</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<#if fileUploadDisable == false>
|
||||
@@ -120,29 +101,18 @@
|
||||
<form enctype="multipart/form-data" id="fileUpload">
|
||||
<div class="form-group">
|
||||
<p id="fileName"></p>
|
||||
<div class="row">
|
||||
<div class="col-md-2">
|
||||
<button type="button" class="btn btn-default" id="fileSelectBtn" style="margin-bottom:8px">
|
||||
<span class="glyphicon glyphicon-cloud-upload" aria-hidden="true"></span> 选择文件
|
||||
</button>
|
||||
</div>
|
||||
<div class="col-md-1">
|
||||
<button id="btnSubmit" type="button" class="btn btn-success">上 传</button>
|
||||
</div>
|
||||
<div class="col-md-9">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<input type="file" name="file" style="display: none" id="fileSelect"
|
||||
onchange="onFileSelected()"/>
|
||||
<button type="button" class="btn btn-default" id="fileSelectBtn" style="margin-bottom:8px">
|
||||
<span class="glyphicon glyphicon-cloud-upload" aria-hidden="true"></span> 选择文件
|
||||
</button>
|
||||
<input type="file" name="file" style="display: none" id="fileSelect" onchange="onFileSelected()"/>
|
||||
<div class="alert alert-danger alert-dismissable hide" role="alert" id="postFileAlert">
|
||||
<button type="button" class="close" data-dismiss="alert" aria-label="Close">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
<strong>请选择需要上传的文件!</strong>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<button id="btnSubmit" type="button" class="btn btn-success">上 传</button>
|
||||
</form>
|
||||
</div>
|
||||
</#if>
|
||||
@@ -198,12 +168,12 @@
|
||||
$(".loading_container").css("height", height).show();
|
||||
}
|
||||
|
||||
function onFileSelected() {
|
||||
function onFileSelected(){
|
||||
var file = $("#fileSelect").val();
|
||||
$("#fileName").text(file);
|
||||
}
|
||||
|
||||
function checkUrl(url) {
|
||||
function checkUrl(url){
|
||||
//url= 协议://(ftp的登录信息)[IP|域名](:端口号)(/或?请求参数)
|
||||
var strRegex = '^((https|http|ftp)://)'//(https或http或ftp)
|
||||
+ '(([\\w_!~*\'()\\.&=+$%-]+: )?[\\w_!~*\'()\\.&=+$%-]+@)?' //ftp的user@ 可有可无
|
||||
@@ -216,7 +186,7 @@
|
||||
+ '(:[0-9]{1,5})?' // 端口- :80 ,1-5位数字
|
||||
+ '((/?)|' // url无参数结尾 - 斜杆或这没有
|
||||
+ '(/[\\w_!~*\'()\\.;?:@&=+$,%#-]+)+/?)$';//请求参数结尾- 英文或数字和[]内的各种字符
|
||||
var re = new RegExp(strRegex, 'i');//i不区分大小写
|
||||
var re = new RegExp(strRegex,'i');//i不区分大小写
|
||||
//将url做uri转码后再匹配,解除请求参数中的中文和空字符影响
|
||||
if (re.test(encodeURI(url))) {
|
||||
return (true);
|
||||
@@ -238,46 +208,47 @@
|
||||
}).on('pre-body.bs.table', function (e, data) {
|
||||
// 每个data添加一列用来操作
|
||||
$(data).each(function (index, item) {
|
||||
item.action = "<a class='btn btn-success' target='_blank' href='${baseUrl}onlinePreview?url=" + encodeURIComponent(Base64.encode('${baseUrl}' + item.fileName)) + "'>预览</a>";
|
||||
item.action = "<a class='btn btn-success' target='_blank' href='${baseUrl}onlinePreview?url=" + encodeURIComponent(Base64.encode('${baseUrl}' + item.fileName)) + "'>预览</a>" +
|
||||
"<a class='btn btn-danger' style='margin-left:10px;' href='javascript:void(0);' onclick='deleteFile(\"" + encodeURIComponent(Base64.encode('${baseUrl}' + item.fileName)) + "\")'>删除</a>";
|
||||
});
|
||||
return data;
|
||||
}).on('post-body.bs.table', function (e, data) {
|
||||
return data;
|
||||
});
|
||||
|
||||
$('#previewByUrl').on('click', function () {
|
||||
$('#previewByUrl').on('click',function() {
|
||||
var _url = $("#_url").val();
|
||||
if (!checkUrl(_url)) {
|
||||
$("#previewCheckAlert").addClass("show");
|
||||
window.setTimeout(function () {
|
||||
window.setTimeout(function(){
|
||||
$("#previewCheckAlert").removeClass("show");
|
||||
}, 3000);//显示的时间
|
||||
},3000);//显示的时间
|
||||
return false;
|
||||
}
|
||||
|
||||
var b64Encoded = Base64.encode(_url);
|
||||
|
||||
window.open('${baseUrl}onlinePreview?url=' + encodeURIComponent(b64Encoded));
|
||||
window.open('${baseUrl}onlinePreview?url='+encodeURIComponent(b64Encoded));
|
||||
});
|
||||
|
||||
$('#fileSelectBtn').on('click', function () {
|
||||
$('#fileSelectBtn').on('click',function() {
|
||||
$('#fileSelect').click();
|
||||
});
|
||||
|
||||
$("#btnSubmit").click(function () {
|
||||
var _fileName = $("#fileName").text()
|
||||
var index = _fileName.lastIndexOf(".");
|
||||
var index= _fileName.lastIndexOf(".");
|
||||
//获取后缀
|
||||
var ext = _fileName.substr(index + 1);
|
||||
if (!ext || ext == "dll" || ext == "exe" || ext == "msi") {
|
||||
window.alert(ext + "不支持上传")
|
||||
return;
|
||||
}
|
||||
if (!_fileName) {
|
||||
var ext = _fileName.substr(index+1);
|
||||
if (!ext || ext == "dll"|| ext == "exe"|| ext == "msi" ){
|
||||
window.alert(ext+"不支持上传")
|
||||
return ;
|
||||
}
|
||||
if(!_fileName){
|
||||
$("#postFileAlert").addClass("show");
|
||||
window.setTimeout(function () {
|
||||
window.setTimeout(function(){
|
||||
$("#postFileAlert").removeClass("show");
|
||||
}, 3000);//显示的时间
|
||||
},3000);//显示的时间
|
||||
return;
|
||||
}
|
||||
showLoadingDiv();
|
||||
@@ -1,98 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html lang="en" xmlns="http://www.w3.org/1999/html">
|
||||
<head>
|
||||
<meta charset="utf-8"/>
|
||||
<meta name="viewport" content="width=device-width, user-scalable=yes, initial-scale=1.0"/>
|
||||
<title>接入说明</title>
|
||||
<link rel="icon" href="./favicon.ico" type="image/x-icon">
|
||||
<link rel="stylesheet" href="css/viewer.min.css"/>
|
||||
<link rel="stylesheet" href="css/loading.css"/>
|
||||
<link rel="stylesheet" href="bootstrap/css/bootstrap.min.css"/>
|
||||
<link rel="stylesheet" href="bootstrap/css/bootstrap-theme.min.css"/>
|
||||
<link rel="stylesheet" href="bootstrap-table/bootstrap-table.min.css"/>
|
||||
<link rel="stylesheet" href="css/theme.css"/>
|
||||
<script type="text/javascript" src="js/jquery-3.6.1.min.js"></script>
|
||||
<script type="text/javascript" src="js/jquery.form.min.js"></script>
|
||||
<script type="text/javascript" src="bootstrap/js/bootstrap.min.js"></script>
|
||||
<script type="text/javascript" src="bootstrap-table/bootstrap-table.min.js"></script>
|
||||
<script type="text/javascript" src="js/base64.min.js"></script>
|
||||
<style>
|
||||
.alert {
|
||||
width: 50%;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<!-- Fixed navbar -->
|
||||
<nav class="navbar navbar-inverse navbar-fixed-top">
|
||||
<div class="container">
|
||||
<div class="navbar-header">
|
||||
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar"
|
||||
aria-expanded="false" aria-controls="navbar">
|
||||
<span class="sr-only">Toggle navigation</span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
</button>
|
||||
<a class="navbar-brand" href="https://kkview.cn" target='_blank'>kkFileView</a>
|
||||
</div>
|
||||
<div id="navbar" class="navbar-collapse collapse">
|
||||
<ul class="nav navbar-nav">
|
||||
<li><a href="./index">首页</a></li>
|
||||
<li class="active"><a href="./integrated">接入说明</a></li>
|
||||
<li><a href="./record">版本发布记录</a></li>
|
||||
<li><a href="./sponsor">赞助开源</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
<div class="container theme-showcase" role="main">
|
||||
<#-- 接入说明 -->
|
||||
<div class="page-header">
|
||||
<h1>接入说明</h1>
|
||||
本文档针对前端项目接入 kkFileView 的说明,并假设 kkFileView 的服务地址为:http://127.0.0.1:8012。
|
||||
</div>
|
||||
<div class="well">
|
||||
|
||||
<div style="font-size: 16px;">
|
||||
【http/https 资源文件预览】如果你的项目需要接入文件预览项目,达到对docx、excel、ppt、jpg等文件的预览效果,那么通过在你的项目中加入下面的代码就可以成功实现:
|
||||
<p style="background-color: #2f332a;color: #cccccc;font-size: 14px;padding:10px;margin-top:10px;">
|
||||
var url = 'http://127.0.0.1:8080/file/test.txt'; //要预览文件的访问地址 <br>
|
||||
window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(base64Encode(url)));
|
||||
</p>
|
||||
</div>
|
||||
<br>
|
||||
<div style="font-size: 16px;">
|
||||
【http/https 流资源文件预览】很多系统内不是直接暴露文件下载地址,而是请求通过id、code等参数到通过统一的接口,后端通过id或code等参数定位文件,再通过OutputStream输出下载,此时下载url是不带文件后缀名的,预览时需要拿到文件名,传一个参数fullfilename=xxx.xxx来指定文件名,示例如下
|
||||
<p style="background-color: #2f332a;color: #cccccc;font-size: 14px;padding:10px;margin-top:10px;">
|
||||
var originUrl = 'http://127.0.0.1:8080/filedownload?fileId=1'; //要预览文件的访问地址<br>
|
||||
var previewUrl = originUrl + '&fullfilename=test.txt'<br>
|
||||
window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(previewUrl)));
|
||||
</p>
|
||||
</div>
|
||||
<br>
|
||||
<div style="font-size: 16px;">
|
||||
【ftp 资源文件预览】如果要预览的FTP url是可以匿名访问的(不需要用户名密码),则可以直接通过下载url预览,示例如下
|
||||
<p style="background-color: #2f332a;color: #cccccc;font-size: 14px;padding:10px;margin-top:10px;">
|
||||
var url = 'ftp://127.0.0.1/file/test.txt'; //要预览文件的访问地址<br>
|
||||
window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(url)));
|
||||
</p>
|
||||
</div>
|
||||
<br>
|
||||
<div style="font-size: 16px;">
|
||||
【ftp 加密资源文件预览】如果 FTP 需要认证访问服,可以通过在 url 中加入用户名密码等参数预览,示例如下
|
||||
<p style="background-color: #2f332a;color: #cccccc;font-size: 14px;padding:10px;margin-top:10px;">
|
||||
var originUrl = 'ftp://127.0.0.1/file/test.txt'; //要预览文件的访问地址<br>
|
||||
var previewUrl = originUrl + '?ftp.username=xx&ftp.password=xx&ftp.control.encoding=xx';<br>
|
||||
window.open('http://127.0.0.1:8012/onlinePreview?url='+encodeURIComponent(Base64.encode(previewUrl)));
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
@@ -1,266 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8"/>
|
||||
<meta name="viewport" content="width=device-width, user-scalable=yes, initial-scale=1.0"/>
|
||||
<title>kkFileView版本记录</title>
|
||||
<link rel="icon" href="./favicon.ico" type="image/x-icon">
|
||||
<link rel="stylesheet" href="css/viewer.min.css"/>
|
||||
<link rel="stylesheet" href="bootstrap/css/bootstrap.min.css"/>
|
||||
<link rel="stylesheet" href="bootstrap/css/bootstrap-theme.min.css"/>
|
||||
<link rel="stylesheet" href="css/theme.css"/>
|
||||
<script type="text/javascript" src="js/jquery-3.6.1.min.js"></script>
|
||||
<script type="text/javascript" src="js/jquery.form.min.js"></script>
|
||||
<script type="text/javascript" src="bootstrap/js/bootstrap.min.js"></script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<!-- Fixed navbar -->
|
||||
<nav class="navbar navbar-inverse navbar-fixed-top">
|
||||
<div class="container">
|
||||
<div class="navbar-header">
|
||||
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar"
|
||||
aria-expanded="false" aria-controls="navbar">
|
||||
<span class="sr-only">Toggle navigation</span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
</button>
|
||||
<a class="navbar-brand" href="https://kkview.cn" target='_blank'>kkFileView</a>
|
||||
</div>
|
||||
<div id="navbar" class="navbar-collapse collapse">
|
||||
<ul class="nav navbar-nav">
|
||||
<li><a href="./index">首页</a></li>
|
||||
<li><a href="./integrated">接入说明</a></li>
|
||||
<li class="active"><a href="./record">版本发布记录</a></li>
|
||||
<li><a href="./sponsor">赞助开源</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
<div class="container theme-showcase" role="main">
|
||||
<#-- 版本发布记录 -->
|
||||
<div class="page-header">
|
||||
<h1>版本发布记录</h1>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2022年12月14日,v4.1.0 版本</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 全新首页视觉 @wsd7747 <br>
|
||||
2. tif图片预览兼容多页tif的pdf转换、jpg转换,以及jpg在线多页预览功能 @zhangzhen1979<br>
|
||||
3. 优化docker构建方案,使用分层构建方式 @yl-yue<br>
|
||||
4. 实现基于userToken缓存加密文件 @yl-yue<br>
|
||||
5. 实现加密word、ppt、excel文件预览 @yl-yue<br>
|
||||
6. Linux & Docker镜像升级LibreOffice 7.3<br>
|
||||
7. 更新OFD预览组件、更新tif预览组件、更新PPT水印支持<br>
|
||||
8. 大量其他升级优化 & 已知问题修复<br>
|
||||
<br>
|
||||
感谢 @yl-yue @wsd7747 @zhangzhen1979 @tomhusky @shenghuadun @kischn.sun 的代码贡献
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2021年7月6日,v4.0.0 版本</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 底层集成OpenOffice替换为LibreOffice,Office文件兼容性增强,预览效果提升<br>
|
||||
2. 修复压缩文件目录穿越漏洞<br>
|
||||
3. 修复PPT预览使用PDF模式无效<br>
|
||||
4. 修复PPT图片预览模式前端显示异常<br>
|
||||
5. 新增功能:首页文件上传功能可通过配置实时开启或禁用<br>
|
||||
6. 优化增加Office进程关闭日志<br>
|
||||
7. 优化Windows环境下,查找Office组件逻辑(内置的LibreOffice优先)<br>
|
||||
8. 优化启动Office进程改同步执行
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2021年6月17日,v3.6.0版本</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
** ofd 类型文件支持版本,本次版本重要功能均由社区开发贡献,感谢 @gaoxingzaq、@zhangxiaoxiao9527 的代码贡献
|
||||
**<br>
|
||||
1. 新增 ofd 类型文件预览支持,ofd 是国产的类似 pdf 格式的文件<br>
|
||||
2. 新增了 ffmpeg 视频文件转码预览支持,打开转码功能后,理论上支持所有主流视频的预览,如 rm、rmvb、flv 等<br>
|
||||
3. 美化了 ppt、pptx 类型文件预览效果,比之前版本好看太多<br>
|
||||
4. 更新了 pdfbox、xstream、common-io 等依赖的版本
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2021年1月28日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
** 2020农历年最后一个版本发布,主要包含了部分 UI 改进,和解决了 QQ 群友、 Issue 里反馈的 Bug
|
||||
修复,最最重要的是发个新版,过个好年 **<br>
|
||||
1. 引入galimatias,解决不规范文件名导致文件下载异常<br>
|
||||
2. 更新index接入演示界面UI风格<br>
|
||||
3. 更新markdown文件预览UI风格<br>
|
||||
4. 更新XML文件预览UI风格,调整类文本预览架构,更方便扩展<br>
|
||||
5. 更新simTxT文件预览UI风格<br>
|
||||
6. 调整多图连续预览上下翻图的UI<br>
|
||||
7. 采用apache-common-io包简化所有的文件下载io操作<br>
|
||||
8. XML文件预览支持切换纯文本模式<br>
|
||||
9. 增强url base64解码失败时的提示信息<br>
|
||||
10. 修复导包错误以及图片预览 bug<br>
|
||||
11. 修复发行包运行时找不到日志目录的问题<br>
|
||||
12. 修复压缩包内多图连续预览的bug<br>
|
||||
13. 修复大小写文件类型后缀没通用匹配的问题<br>
|
||||
14. 指定Base64转码采用Apache Commons-code中的实现,修复base64部分jdk版本下出现的异常<br>
|
||||
15. 修复类文本类型HTML文件预览的bug<br>
|
||||
16. 修复:dwg文件预览时无法在jpg和pdf两种类型之间切换<br>
|
||||
17. escaping of dangerous characters to prevent reflected xss<br>
|
||||
18. 修复重复编码导致文档转图片预览失败的问题&编码规范
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2020年12月27日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
** 2020年年终大版本更新,架构全面设计,代码全面重构,代码质量全面提升,二次开发更便捷,欢迎拉源码品鉴,提issue、pr共同建设
|
||||
**<br>
|
||||
1. 架构模块调整,大量的代码重构,代码质量提升N个等级,欢迎品鉴<br>
|
||||
2. 增强XML文件预览效果,新增XML文档数结构预览<br>
|
||||
3. 新增markdown文件预览支持,预览支持md渲染和源文本切换支持<br>
|
||||
4. 切换底层web server为jetty,解决这个issue:<a href="https://github.com/kekingcn/kkFileView/issues/168">#issues/168</a><br>
|
||||
5. 引入cpdetector,解决文件编码识别问题<br>
|
||||
6. url采用base64+urlencode双编码,彻底解决各种奇葩文件名预览问题<br>
|
||||
7. 新增配置项office.preview.switch.disabled,控制offic文件预览切换开关<br>
|
||||
8. 优化文本类型文件预览逻辑,采用Base64传输内容,避免预览时再次请求文件内容<br>
|
||||
9. office预览图片模式禁用图片放大效果,达到图片和pdf预览效果一致的体验<br>
|
||||
10. 直接代码静态设置pdfbox兼容低版本jdk,在IDEA中运行也不会有警告提示<br>
|
||||
11. 移除guava、hutool等非必须的工具包,减少代码体积<br>
|
||||
12. Office组件加载异步化,提速应用启动速度最快到5秒内<br>
|
||||
13. 合理设置预览消费队列的线程数<br>
|
||||
14. 修复压缩包里文件再次预览失败的bug<br>
|
||||
15. 修复图片预览的bug
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2020年05月20日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 新增支持全局水印,并支持通过参数动态改变水印内容<br>
|
||||
2. 新增支持CAD文件预览<br>
|
||||
3. 新增base.url配置,支持使用nginx反向代理和使用context-path<br>
|
||||
4. 支持所有配置项支持从环境变量里读取,方便Docker镜像部署和集群中大规模使用<br>
|
||||
5. 支持配置限信任站点(只能预览来自信任点的文件源),保护预览服务不被滥用<br>
|
||||
6. 支持配置自定义缓存清理时间(cron表达式)<br>
|
||||
7. 全部能识别的纯文本直接预览,不用再转跳下载,如.md .java .py等<br>
|
||||
8. 支持配置限制转换后的PDF文件下载<br>
|
||||
9. 优化maven打包配置,解决 .sh 脚本可能出现换行符问题<br>
|
||||
10. 将前端所有CDN依赖放到本地,方便没有外网连接的用户使用<br>
|
||||
11. 首页评论服务由搜狐畅言切换到Gitalk<br>
|
||||
12. 修复url中包含特殊字符可能会引起的预览异常<br>
|
||||
13. 修复转换文件队列addTask异常<br>
|
||||
14. 修复其他已经问题<br>
|
||||
15. 官网建设:<a href="https://kkview.cn">https://kkview.cn</a><br>
|
||||
16. 官方Docker镜像仓库建设:<a href="https://hub.docker.com/r/keking/kkfileview">https://hub.docker.com/r/keking/kkfileview</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2019年06月18日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 支持自动清理缓存及预览文件<br>
|
||||
2. 支持http/https下载流url文件预览<br>
|
||||
3. 支持FTP url文件预览<br>
|
||||
4. 加入Docker构建
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2019年04月08日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 缓存及队列实现抽象,提供JDK和REDIS两种实现(REDIS成为可选依赖)<br>
|
||||
2. 打包方式提供zip和tar.gz包,并提供一键启动脚本
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2018年01月19日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 大文件入队提前处理<br>
|
||||
2. 新增addTask文件转换入队接口<br>
|
||||
3. 采用redis队列,支持kkFIleView接口和异构系统入队两种方式
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2018年01月15日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 首页新增社会化评论框
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2018年01月12日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 新增多图片同时预览<br>
|
||||
2. 支持压缩包内图片轮番预览
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2018年01月02日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 修复txt等文本编码问题导致预览乱码<br>
|
||||
2. 修复项目模块依赖引入不到的问题<br>
|
||||
3. 新增spring boot profile,支持多环境配置<br>
|
||||
4. 引入pdf.js预览doc等文件,支持doc标题生成pdf预览菜单,支持手机端预览
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2017年12月12日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 项目gitee开源:<a href="https://gitee.com/kekingcn/file-online-preview" target="_blank">https://gitee.com/kekingcn/file-online-preview</a><br>
|
||||
2. 项目github开源:<a href="https://github.com/kekingcn/kkFileView" target="_blank">https://github.com/kekingcn/kkFileView</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@@ -1,90 +0,0 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html lang="en" xmlns="http://www.w3.org/1999/html">
|
||||
<head>
|
||||
<meta charset="utf-8"/>
|
||||
<meta name="viewport" content="width=device-width, user-scalable=yes, initial-scale=1.0"/>
|
||||
<title>赞助开源</title>
|
||||
<link rel="icon" href="./favicon.ico" type="image/x-icon">
|
||||
<link rel="stylesheet" href="css/viewer.min.css"/>
|
||||
<link rel="stylesheet" href="css/loading.css"/>
|
||||
<link rel="stylesheet" href="bootstrap/css/bootstrap.min.css"/>
|
||||
<link rel="stylesheet" href="bootstrap/css/bootstrap-theme.min.css"/>
|
||||
<link rel="stylesheet" href="bootstrap-table/bootstrap-table.min.css"/>
|
||||
<link rel="stylesheet" href="css/theme.css"/>
|
||||
<script type="text/javascript" src="js/jquery-3.6.1.min.js"></script>
|
||||
<script type="text/javascript" src="js/jquery.form.min.js"></script>
|
||||
<script type="text/javascript" src="bootstrap/js/bootstrap.min.js"></script>
|
||||
<script type="text/javascript" src="bootstrap-table/bootstrap-table.min.js"></script>
|
||||
<script type="text/javascript" src="js/base64.min.js"></script>
|
||||
<style>
|
||||
.alert {
|
||||
width: 50%;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<!-- Fixed navbar -->
|
||||
<nav class="navbar navbar-inverse navbar-fixed-top">
|
||||
<div class="container">
|
||||
<div class="navbar-header">
|
||||
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar"
|
||||
aria-expanded="false" aria-controls="navbar">
|
||||
<span class="sr-only">Toggle navigation</span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
</button>
|
||||
<a class="navbar-brand" href="https://kkview.cn" target='_blank'>kkFileView</a>
|
||||
</div>
|
||||
<div id="navbar" class="navbar-collapse collapse">
|
||||
<ul class="nav navbar-nav">
|
||||
<li><a href="./index">首页</a></li>
|
||||
<li><a href="./integrated">接入说明</a></li>
|
||||
<li><a href="./record">版本发布记录</a></li>
|
||||
<li class="active"><a href="./sponsor">赞助开源</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
<div class="container theme-showcase" role="main">
|
||||
<#-- 接入说明 -->
|
||||
<div class="page-header">
|
||||
<h1>赞助开源</h1>
|
||||
<ur style="font-size: 16px;">
|
||||
<li>kkFileView 开源至今已 6 个年头,积累 <a target="_blank" href="https://gitee.com/kekingcn/file-online-preview">Gitee(16.9K)</a>、<a target="_blank" href="https://github.com/kekingcn/kkFileView">GitHub(8k)</a> 多的 star</li>
|
||||
<li>kkFileView 被广泛应用于金融、教育、银行、政务、计算机等行业, 不完全统计有 200+ 企业在使用</li>
|
||||
<li>kkFileView 每年的文档站点、演示站点的服务器、CDN 资源, 至少在 1000元以上</li>
|
||||
<li>kkFileView 是一款完全开源的在线预览项目,如果你觉得 kkFileView 对你有帮助,可以通过下面的方式来赞助我们,谢谢!</li>
|
||||
</ur>
|
||||
</div>
|
||||
<div>
|
||||
<div style="font-size: 16px;">
|
||||
<img width="400px" height="550px" src="/images/alipay.jpeg"/> <img width="400px" height="550px" src="/images/wxpay.jpeg"/>
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<h3>赞助记录</h3>
|
||||
2023-03-14 开启赞助通道,赞助记录为手动录入的,存在周级别延迟,如有遗漏,请联系作者补充
|
||||
<br/>
|
||||
<table class="table table-striped table-bordered">
|
||||
<tr>
|
||||
<th>赞助人</th>
|
||||
<th>赞助金额</th>
|
||||
<th>赞助时间</th>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>陈**</td>
|
||||
<td>99</td>
|
||||
<td>2023-03-14</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
261
server/src/main/resources/web/record.ftl
Normal file
261
server/src/main/resources/web/record.ftl
Normal file
@@ -0,0 +1,261 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8"/>
|
||||
<meta name="viewport" content="width=device-width, user-scalable=yes, initial-scale=1.0"/>
|
||||
<title>kkFileView版本记录</title>
|
||||
<link rel="icon" href="./favicon.ico" type="image/x-icon">
|
||||
<link rel="stylesheet" href="css/viewer.min.css"/>
|
||||
<link rel="stylesheet" href="bootstrap/css/bootstrap.min.css"/>
|
||||
<link rel="stylesheet" href="bootstrap/css/bootstrap-theme.min.css"/>
|
||||
<link rel="stylesheet" href="css/theme.css"/>
|
||||
<script type="text/javascript" src="js/jquery-3.6.1.min.js"></script>
|
||||
<script type="text/javascript" src="js/jquery.form.min.js"></script>
|
||||
<script type="text/javascript" src="bootstrap/js/bootstrap.min.js"></script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<!-- Fixed navbar -->
|
||||
<nav class="navbar navbar-inverse navbar-fixed-top">
|
||||
<div class="container">
|
||||
<div class="navbar-header">
|
||||
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
|
||||
<span class="sr-only">Toggle navigation</span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
</button>
|
||||
<a class="navbar-brand" href="https://kkview.cn" target='_blank'>kkFileView</a>
|
||||
</div>
|
||||
<div id="navbar" class="navbar-collapse collapse">
|
||||
<ul class="nav navbar-nav">
|
||||
<li><a href="./index">首页</a></li>
|
||||
<li class="active"><a href="./record">版本发布记录</a></li>
|
||||
<li><a href="./comment">相关交流</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
<div class="container theme-showcase" role="main">
|
||||
<#-- 版本发布记录 -->
|
||||
<div class="page-header">
|
||||
<h1>版本发布记录</h1>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2022年12月14日,v4.1.0 版本</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 全新首页视觉 @wsd7747 <br>
|
||||
2. tif图片预览兼容多页tif的pdf转换、jpg转换,以及jpg在线多页预览功能 @zhangzhen1979<br>
|
||||
3. 优化docker构建方案,使用分层构建方式 @yl-yue<br>
|
||||
4. 实现基于userToken缓存加密文件 @yl-yue<br>
|
||||
5. 实现加密word、ppt、excel文件预览 @yl-yue<br>
|
||||
6. Linux & Docker镜像升级LibreOffice 7.3<br>
|
||||
7. 更新OFD预览组件、更新tif预览组件、更新PPT水印支持<br>
|
||||
8. 大量其他升级优化 & 已知问题修复<br>
|
||||
<br>
|
||||
感谢 @yl-yue @wsd7747 @zhangzhen1979 @tomhusky @shenghuadun @kischn.sun 的代码贡献
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2021年7月6日,v4.0.0 版本</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 底层集成OpenOffice替换为LibreOffice,Office文件兼容性增强,预览效果提升<br>
|
||||
2. 修复压缩文件目录穿越漏洞<br>
|
||||
3. 修复PPT预览使用PDF模式无效<br>
|
||||
4. 修复PPT图片预览模式前端显示异常<br>
|
||||
5. 新增功能:首页文件上传功能可通过配置实时开启或禁用<br>
|
||||
6. 优化增加Office进程关闭日志<br>
|
||||
7. 优化Windows环境下,查找Office组件逻辑(内置的LibreOffice优先)<br>
|
||||
8. 优化启动Office进程改同步执行
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2021年6月17日,v3.6.0版本</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
** ofd 类型文件支持版本,本次版本重要功能均由社区开发贡献,感谢 @gaoxingzaq、@zhangxiaoxiao9527 的代码贡献 **<br>
|
||||
1. 新增 ofd 类型文件预览支持,ofd 是国产的类似 pdf 格式的文件<br>
|
||||
2. 新增了 ffmpeg 视频文件转码预览支持,打开转码功能后,理论上支持所有主流视频的预览,如 rm、rmvb、flv 等<br>
|
||||
3. 美化了 ppt、pptx 类型文件预览效果,比之前版本好看太多<br>
|
||||
4. 更新了 pdfbox、xstream、common-io 等依赖的版本
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2021年1月28日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
** 2020农历年最后一个版本发布,主要包含了部分 UI 改进,和解决了 QQ 群友、 Issue 里反馈的 Bug 修复,最最重要的是发个新版,过个好年 **<br>
|
||||
1. 引入galimatias,解决不规范文件名导致文件下载异常<br>
|
||||
2. 更新index接入演示界面UI风格<br>
|
||||
3. 更新markdown文件预览UI风格<br>
|
||||
4. 更新XML文件预览UI风格,调整类文本预览架构,更方便扩展<br>
|
||||
5. 更新simTxT文件预览UI风格<br>
|
||||
6. 调整多图连续预览上下翻图的UI<br>
|
||||
7. 采用apache-common-io包简化所有的文件下载io操作<br>
|
||||
8. XML文件预览支持切换纯文本模式<br>
|
||||
9. 增强url base64解码失败时的提示信息<br>
|
||||
10. 修复导包错误以及图片预览 bug<br>
|
||||
11. 修复发行包运行时找不到日志目录的问题<br>
|
||||
12. 修复压缩包内多图连续预览的bug<br>
|
||||
13. 修复大小写文件类型后缀没通用匹配的问题<br>
|
||||
14. 指定Base64转码采用Apache Commons-code中的实现,修复base64部分jdk版本下出现的异常<br>
|
||||
15. 修复类文本类型HTML文件预览的bug<br>
|
||||
16. 修复:dwg文件预览时无法在jpg和pdf两种类型之间切换<br>
|
||||
17. escaping of dangerous characters to prevent reflected xss<br>
|
||||
18. 修复重复编码导致文档转图片预览失败的问题&编码规范
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2020年12月27日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
** 2020年年终大版本更新,架构全面设计,代码全面重构,代码质量全面提升,二次开发更便捷,欢迎拉源码品鉴,提issue、pr共同建设 **<br>
|
||||
1. 架构模块调整,大量的代码重构,代码质量提升N个等级,欢迎品鉴<br>
|
||||
2. 增强XML文件预览效果,新增XML文档数结构预览<br>
|
||||
3. 新增markdown文件预览支持,预览支持md渲染和源文本切换支持<br>
|
||||
4. 切换底层web server为jetty,解决这个issue:<a href="https://github.com/kekingcn/kkFileView/issues/168">#issues/168</a><br>
|
||||
5. 引入cpdetector,解决文件编码识别问题<br>
|
||||
6. url采用base64+urlencode双编码,彻底解决各种奇葩文件名预览问题<br>
|
||||
7. 新增配置项office.preview.switch.disabled,控制offic文件预览切换开关<br>
|
||||
8. 优化文本类型文件预览逻辑,采用Base64传输内容,避免预览时再次请求文件内容<br>
|
||||
9. office预览图片模式禁用图片放大效果,达到图片和pdf预览效果一致的体验<br>
|
||||
10. 直接代码静态设置pdfbox兼容低版本jdk,在IDEA中运行也不会有警告提示<br>
|
||||
11. 移除guava、hutool等非必须的工具包,减少代码体积<br>
|
||||
12. Office组件加载异步化,提速应用启动速度最快到5秒内<br>
|
||||
13. 合理设置预览消费队列的线程数<br>
|
||||
14. 修复压缩包里文件再次预览失败的bug<br>
|
||||
15. 修复图片预览的bug
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2020年05月20日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 新增支持全局水印,并支持通过参数动态改变水印内容<br>
|
||||
2. 新增支持CAD文件预览<br>
|
||||
3. 新增base.url配置,支持使用nginx反向代理和使用context-path<br>
|
||||
4. 支持所有配置项支持从环境变量里读取,方便Docker镜像部署和集群中大规模使用<br>
|
||||
5. 支持配置限信任站点(只能预览来自信任点的文件源),保护预览服务不被滥用<br>
|
||||
6. 支持配置自定义缓存清理时间(cron表达式)<br>
|
||||
7. 全部能识别的纯文本直接预览,不用再转跳下载,如.md .java .py等<br>
|
||||
8. 支持配置限制转换后的PDF文件下载<br>
|
||||
9. 优化maven打包配置,解决 .sh 脚本可能出现换行符问题<br>
|
||||
10. 将前端所有CDN依赖放到本地,方便没有外网连接的用户使用<br>
|
||||
11. 首页评论服务由搜狐畅言切换到Gitalk<br>
|
||||
12. 修复url中包含特殊字符可能会引起的预览异常<br>
|
||||
13. 修复转换文件队列addTask异常<br>
|
||||
14. 修复其他已经问题<br>
|
||||
15. 官网建设:<a href="https://kkview.cn">https://kkview.cn</a><br>
|
||||
16. 官方Docker镜像仓库建设:<a href="https://hub.docker.com/r/keking/kkfileview">https://hub.docker.com/r/keking/kkfileview</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2019年06月18日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 支持自动清理缓存及预览文件<br>
|
||||
2. 支持http/https下载流url文件预览<br>
|
||||
3. 支持FTP url文件预览<br>
|
||||
4. 加入Docker构建
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2019年04月08日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 缓存及队列实现抽象,提供JDK和REDIS两种实现(REDIS成为可选依赖)<br>
|
||||
2. 打包方式提供zip和tar.gz包,并提供一键启动脚本
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2018年01月19日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 大文件入队提前处理<br>
|
||||
2. 新增addTask文件转换入队接口<br>
|
||||
3. 采用redis队列,支持kkFIleView接口和异构系统入队两种方式
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2018年01月15日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 首页新增社会化评论框
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2018年01月12日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 新增多图片同时预览<br>
|
||||
2. 支持压缩包内图片轮番预览
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2018年01月02日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 修复txt等文本编码问题导致预览乱码<br>
|
||||
2. 修复项目模块依赖引入不到的问题<br>
|
||||
3. 新增spring boot profile,支持多环境配置<br>
|
||||
4. 引入pdf.js预览doc等文件,支持doc标题生成pdf预览菜单,支持手机端预览
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel panel-success">
|
||||
<div class="panel-heading">
|
||||
<h3 class="panel-title">2017年12月12日</h3>
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<div>
|
||||
1. 项目gitee开源:<a href="https://gitee.com/kekingcn/file-online-preview" target="_blank">https://gitee.com/kekingcn/file-online-preview</a><br>
|
||||
2. 项目github开源:<a href="https://github.com/kekingcn/kkFileView" target="_blank">https://github.com/kekingcn/kkFileView</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user