HornsAndHooves-publify_core 10.0.3 → 10.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c608c462079f3d5fd64160d1506e7c90f4912c65120fdaf3e65e2d144420ed93
4
- data.tar.gz: e9b8ccb059eb98cb23a310edd1d26acd41fbfa2a3a01ed68d10e4b6531cacf4d
3
+ metadata.gz: 109eaa0d80e831ff83cd6067dfa3920895e59ef465533d2e6ee2346275a1191d
4
+ data.tar.gz: 2e2319019464945e2c6abe8d9434dc8505900fc13d163b3f58fed20e0063ddf2
5
5
  SHA512:
6
- metadata.gz: '064290a1fb5c58f8377b5b5f1def37eaeecfb3534fb619dbd9bbe58771c6f399ef38932304b3a4d3c8a8c04475ef262f544b267fff85a4c813e92db568475227'
7
- data.tar.gz: 1e70d5f710253599e2059d3a9632c3509495cd6b54f9f6922e2e13416790fee8a5a70ef41eb0287c23c36b75eedceac6a8ad5caaac09b5ae9f8769c6771440e9
6
+ metadata.gz: 8ba568f08175773bc85e078b69e099afd3286a4ca1a8ac29fde85e68b81f0529ebc1bdfb58cc8fe726c28e2cbbb10c276502145e7b5283095c6d46be7830e14d
7
+ data.tar.gz: 7eeed9172a3c7e4c0ef49668068f7587d16e2131ecd97d0214fc1e78fcc9372e17ede1d10931540ff919b8c5550a9bc775b02c251c14d4913f4f94e5adcd9048
@@ -136,6 +136,15 @@ select#article_resource_id:invalid {
136
136
  color: gray;
137
137
  }
138
138
 
139
+ #article_image_alt {
140
+ border: none;
141
+ -webkit-box-shadow: none;
142
+ box-shadow: none;
143
+ -webkit-transition: none;
144
+ transition: none;
145
+ padding-left: 4px;
146
+ }
147
+
139
148
  #article_body_and_extended,
140
149
  #page_body {
141
150
  font-size: 1.3em;
@@ -113,7 +113,7 @@ class Admin::ContentController < Admin::BaseController
113
113
  @article.author = current_user
114
114
  @article.save_attachments!(params[:attachments])
115
115
  @article.state = "draft" unless @article.withdrawn?
116
- @article.text_filter_name ||= current_user.text_filter.name
116
+ @article.text_filter_name ||= current_user.text_filter&.name || this_blog.text_filter
117
117
 
118
118
  if @article.title.blank?
119
119
  lastid = Article.order("id desc").first.id
@@ -185,7 +185,8 @@ class Admin::ContentController < Admin::BaseController
185
185
  :permalink,
186
186
  :published_at,
187
187
  :title,
188
- :keywords)
188
+ :keywords,
189
+ :excerpt)
189
190
  end
190
191
 
191
192
  def default_text_filter
@@ -6,7 +6,6 @@ class ArticlesController < ContentController
6
6
  before_action :login_required, only: [:preview, :preview_page]
7
7
  before_action :auto_discovery_feed, only: [:show, :index]
8
8
  before_action :verify_config
9
- before_action :populate_recent_articles, only: [:redirect, :preview]
10
9
 
11
10
  layout :theme_layout, except: [:trackback]
12
11
 
@@ -66,6 +65,8 @@ class ArticlesController < ContentController
66
65
  @article = Article.last_draft(params[:id])
67
66
  @page_title = this_blog.article_title_template.to_title(@article, this_blog, params)
68
67
 
68
+ populate_recent_articles
69
+
69
70
  render "read"
70
71
  end
71
72
 
@@ -85,6 +86,9 @@ class ArticlesController < ContentController
85
86
  factory = Article::Factory.new(this_blog, current_user)
86
87
 
87
88
  @article = factory.match_permalink_format(from, this_blog.permalink_format)
89
+
90
+ populate_recent_articles
91
+
88
92
  return show_article if @article
89
93
 
90
94
  # Redirect old version with /:year/:month/:day/:title to new format,
@@ -160,6 +164,8 @@ class ArticlesController < ContentController
160
164
 
161
165
  private def populate_recent_articles
162
166
  @recent_articles = this_blog.contents.published.limit(RECENT_ARTICLES_COUNT)
167
+
168
+ @recent_articles = @recent_articles.where.not(id: @article.id) if @article
163
169
  end
164
170
 
165
171
  # See an article We need define @article before
@@ -31,7 +31,7 @@ class SetupController < BaseController
31
31
 
32
32
  # EmailNotify.send_user_create_notification(@user)
33
33
 
34
- redirect_to confirm_accounts_url
34
+ redirect_to admin_dashboard_url
35
35
  end
36
36
 
37
37
  private
@@ -31,6 +31,7 @@
31
31
  <div class="col-md-8">
32
32
  <%= text_field 'article', 'title', class: 'form-control', placeholder: t('.title') %>
33
33
  <%= select 'article', 'resource_id', resource_options, { prompt: 'Select Image' }, { class: 'form-control', required: "required" } %>
34
+ <%= text_field 'article', 'image_alt', class: 'form-control', placeholder: t('.image_alt') %>
34
35
  <div id="editor">
35
36
  <%= text_area('article', 'body_and_extended', class: 'form-control ', style: 'height: 360px', placeholder: t('.type_your_post')) %>
36
37
  </div>
@@ -133,6 +134,22 @@
133
134
  </p>
134
135
  </div>
135
136
  </div>
137
+ <div class='control-group'>
138
+ <p>
139
+ <%= t('.excerpt') %>:
140
+ <%= toggle_element('excerpt') %>
141
+ </p>
142
+ <div id="excerpt" class="collapse">
143
+ <div class="form-group">
144
+ <%= text_field 'article', 'excerpt', autocomplete: 'off', class: 'form-control' %>
145
+ </div>
146
+ <p>
147
+ <span class="btn btn-mini btn-default">
148
+ <%= toggle_element('excerpt', t('.ok')) %>
149
+ </span>
150
+ </p>
151
+ </div>
152
+ </div>
136
153
  </fieldset>
137
154
  </div>
138
155
  </div>
@@ -43,6 +43,7 @@ en:
43
43
  article_type: Article type
44
44
  cancel: Cancel
45
45
  default: Default
46
+ excerpt: Excerpt(Meta description)
46
47
  now: now
47
48
  ok: OK
48
49
  password: Password
@@ -59,6 +60,7 @@ en:
59
60
  tags: Tags
60
61
  tags_explanation_html: Separate tags with commas. Use double quotes (&quot;) around multi-word tags, e.g. &quot;opera house&quot;.
61
62
  title: Title
63
+ image_alt: Image Alt Text
62
64
  type_your_post: Type your post
63
65
  visibility: Visibility
64
66
  index:
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module PublifyCore
4
- VERSION = "10.0.3"
4
+ VERSION = "10.1.0"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: HornsAndHooves-publify_core
3
3
  version: !ruby/object:Gem::Version
4
- version: 10.0.3
4
+ version: 10.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matijs van Zuijlen
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2022-07-06 00:00:00.000000000 Z
14
+ date: 2022-08-31 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: aasm