Browse Source

编辑器配置

懒得勤快 4 years ago
parent
commit
cf7a7228df

+ 1 - 1
src/Masuit.MyBlogs.Core/Controllers/BaseController.cs

@@ -89,7 +89,7 @@ namespace Masuit.MyBlogs.Core.Controllers
                 return text;
             }
 
-            var keys = Regex.Matches(text, @"\{\{\w+\}\}").Select(m => m.Value).Join(",");
+            var keys = Regex.Matches(text, @"\{\{[\w._-]+\}\}").Select(m => m.Value).Join(",");
             if (!string.IsNullOrEmpty(keys))
             {
                 var dic = VariablesService.GetQueryFromCache(v => keys.Contains(v.Key)).ToDictionary(v => v.Key, v => v.Value);

+ 6 - 6
src/Masuit.MyBlogs.Core/Masuit.MyBlogs.Core.csproj

@@ -52,11 +52,11 @@
         <PackageReference Include="IP2Region" Version="1.2.0" />
         <PackageReference Include="Karambolo.AspNetCore.Bundling.NUglify" Version="3.4.1" />
         <PackageReference Include="MaxMind.GeoIP2" Version="4.0.1" />
-        <PackageReference Include="Microsoft.EntityFrameworkCore.Sqlite" Version="5.0.0" />
-        <PackageReference Include="Microsoft.AspNetCore.Mvc.NewtonsoftJson" Version="5.0.0" />
-        <PackageReference Include="Microsoft.AspNetCore.SignalR.Protocols.NewtonsoftJson" Version="5.0.0" />
-        <PackageReference Include="Microsoft.EntityFrameworkCore.Proxies" Version="5.0.0" />
-        <PackageReference Include="Microsoft.Graph" Version="3.20.0" />
+        <PackageReference Include="Microsoft.EntityFrameworkCore.Sqlite" Version="5.0.1" />
+        <PackageReference Include="Microsoft.AspNetCore.Mvc.NewtonsoftJson" Version="5.0.1" />
+        <PackageReference Include="Microsoft.AspNetCore.SignalR.Protocols.NewtonsoftJson" Version="5.0.1" />
+        <PackageReference Include="Microsoft.EntityFrameworkCore.Proxies" Version="5.0.1" />
+        <PackageReference Include="Microsoft.Graph" Version="3.21.0" />
         <PackageReference Include="Microsoft.Graph.Auth" Version="1.0.0-preview.6" />
         <PackageReference Include="MiniProfiler.AspNetCore.Mvc" Version="4.2.1" />
         <PackageReference Include="OpenXmlPowerTools-NetStandard" Version="4.4.21" />
@@ -69,7 +69,7 @@
         <PackageReference Include="TimeZoneConverter" Version="3.3.0" />
         <PackageReference Include="WilderMinds.RssSyndication" Version="1.7.0" />
         <PackageReference Include="WinInsider.System.Net.Http.Formatting" Version="1.0.14" />
-        <PackageReference Include="Z.EntityFramework.Plus.EFCore" Version="5.1.5" />
+        <PackageReference Include="Z.EntityFramework.Plus.EFCore" Version="5.1.6" />
     </ItemGroup>
     <ItemGroup>
         <Content Update="appsettings.json">

+ 9 - 9
src/Masuit.MyBlogs.Core/wwwroot/Assets/UEditor/ueditor.config.admin.js

@@ -51,7 +51,7 @@
             'underline', //下划线
             'strikethrough', //删除线
             'subscript', //下标
-            'fontborder', //字符边框
+            //'fontborder', //字符边框
             'superscript', //上标
             'formatmatch', //格式刷
             'blockquote', //引用
@@ -82,7 +82,7 @@
             'imageleft', //左浮动
             'imageright', //右浮动
             'imagecenter', //居中
-            'spechars', //特殊字符
+            //'spechars', //特殊字符
             'searchreplace', //查询替换
             'insertorderedlist', //有序列表
             'insertunorderedlist', //无序列表
@@ -109,21 +109,21 @@
             //'gmap', //Google地图
             //'help', //帮助
             //'fullscreen', //全屏
-            'directionalityltr', //从左向右输入
-            'directionalityrtl', //从右向左输入
-            'rowspacingtop', //段前距
-            'rowspacingbottom', //段后距
+            //'directionalityltr', //从左向右输入
+            //'directionalityrtl', //从右向左输入
+            //'rowspacingtop', //段前距
+            //'rowspacingbottom', //段后距
             //'pagebreak', //分页
-            //'insertframe', //插入Iframe
+            'insertframe', //插入Iframe
             'attachment', //附件
-            'wordimage', //图片转存
+            //'wordimage', //图片转存
             'lineheight', //行间距
             //'edittip ', //编辑提示
             //'webapp', //百度应用
             //'touppercase', //字母大写
             //'tolowercase', //字母小写
             //'background', //背景
-            'template', //模板
+            //'template', //模板
             //'music', //音乐
             //'drafts', // 从草稿箱加载
             //'charts', // 图表

File diff suppressed because it is too large
+ 0 - 0
src/Masuit.MyBlogs.Core/wwwroot/Assets/UEditor/ueditor.config.admin.min.js


+ 4 - 4
src/Masuit.MyBlogs.Core/wwwroot/Assets/UEditor/ueditor.config.front.js

@@ -50,7 +50,7 @@
             'underline', //下划线
             'strikethrough', //删除线
             'subscript', //下标
-            'fontborder', //字符边框
+            //'fontborder', //字符边框
             'superscript', //上标
             'formatmatch', //格式刷
             'blockquote', //引用
@@ -71,7 +71,7 @@
             'paragraph', //段落格式
             'insertcode', //代码语言
             'simpleupload', //单图上传
-            //'insertimage', //多图上传
+            'insertimage', //多图上传
             //'scrawl', //涂鸦
             //'insertvideo', //视频
             //'selectall', //全选
@@ -110,8 +110,8 @@
             //'fullscreen', //全屏
             //'directionalityltr', //从左向右输入
             //'directionalityrtl', //从右向左输入
-            'rowspacingtop', //段前距
-            'rowspacingbottom', //段后距
+            //'rowspacingtop', //段前距
+            //'rowspacingbottom', //段后距
             //'pagebreak', //分页
             //'insertframe', //插入Iframe
             //'attachment', //附件

File diff suppressed because it is too large
+ 0 - 0
src/Masuit.MyBlogs.Core/wwwroot/Assets/UEditor/ueditor.config.front.min.js


+ 1 - 2
src/Masuit.MyBlogs.Core/wwwroot/ng-views/views/values.html

@@ -32,14 +32,13 @@
                     变量名:
                 </span>
                 <div class="fg-line">
-                    <input type="text" class="form-control" ng-model="values.Key" />
+                    <input type="text" class="form-control" ng-model="values.Key"  ng-disabled="values.Id>0"/>
                 </div>
             </div>
             <div class="input-group">
                 <span class="input-group-addon">
                     变量值:
                 </span>
-                <!--<div class="ueditor max-height400" ng-model="values.Value" type="text/plain"></div>-->
                 <div style="height: 300px;" class="ueditor" ng-model="values.Value" type="text/plain"></div>
             </div>
             <div class="btn-group">

Some files were not shown because too many files changed in this diff