Skip to content
This repository was archived by the owner on Jul 22, 2025. It is now read-only.

Commit 9d9b6ab

Browse files
committed
Add Carbon Ads locations
1 parent 9c6c880 commit 9d9b6ab

File tree

3 files changed

+12
-2
lines changed

3 files changed

+12
-2
lines changed

assets/javascripts/discourse/components/ad-slot.gjs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,9 +56,9 @@ const adConfig = EmberObject.create({
5656
enabledSetting: "carbonads_serve_id",
5757
desktop: {
5858
"topic-list-top": "carbonads_topic_list_top_enabled",
59-
"post-bottom": false,
59+
"post-bottom": "carbonads_post_bottom_enabled",
6060
"topic-above-post-stream": "carbonads_above_post_stream_enabled",
61-
"topic-above-suggested": false,
61+
"topic-above-suggested": "carbonads_above_suggested_enabled",
6262
},
6363
},
6464
"adbutler-ad": {

config/locales/server.en.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,8 @@ en:
102102
carbonads_exclude_groups: "Ads will not be shown to members of these groups"
103103
carbonads_topic_list_top_enabled: "Show an ad above the topic list"
104104
carbonads_above_post_stream_enabled: "Show an ad above the post stream"
105+
carbonads_post_bottom_enabled: "Show an ad above at post bottom"
106+
carbonads_above_suggested_enabled: "Show an ad above the above suggested topics"
105107

106108
adbutler_publisher_id: "AdButler Publisher ID. NOTE: You may need to update the 'content security policy script src' setting. See <a href='https://meta.discourse.org/t/33734' target='_blank'>this topic</a> for the latest instructions."
107109
adbutler_mobile_topic_list_top_zone_id: "Zone ID for mobile topic list top location"

config/settings.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -440,7 +440,9 @@ carbonads_plugin:
440440
default: ""
441441
carbonads_format:
442442
client: true
443+
type: enum
443444
default: "responsive"
445+
allow_any: false
444446
choices:
445447
- responsive
446448
- cover
@@ -469,6 +471,12 @@ carbonads_plugin:
469471
carbonads_above_post_stream_enabled:
470472
client: true
471473
default: false
474+
carbonads_post_bottom_enabled:
475+
client: true
476+
default: false
477+
carbonads_above_suggested_enabled:
478+
client: true
479+
default: false
472480

473481
adbutler_plugin:
474482
adbutler_publisher_id:

0 commit comments

Comments
 (0)