581 Commits

Author SHA1 Message Date
Jarek Radosz
bc68d6e230
DEV: Fix migration timestamp (#254) 2025-07-22 11:20:13 +01:00
Jarek Radosz
b521d3e909
DEV: Mention the core move in readme (#253) 2025-07-22 11:00:07 +01:00
Jarek Radosz
e9c3c335f2
DEV: Disable the plugin by default (#252)
…and preserve the current setting on existing sites
2025-07-22 11:50:37 +02:00
Jarek Radosz
0171ad8d3a
Revert "DEV: Deprecate the plugin (#250)" (#251)
This reverts commit 7d341446159d0d26f5da8e6e473742310c7ce737.
2025-07-15 10:25:25 +01:00
Jarek Radosz
7d34144615
DEV: Deprecate the plugin (#250) 2025-07-14 10:16:57 +01:00
Sérgio Saquetim
8a3263d050
DEV: Add compatibility with the Glimmer Post Stream (#247)
This commit updates the ad plugin to support the Glimmer Post Stream and refactors ad rendering logic for improved compatibility and maintainability.

Key changes:

- Introduce glimmer_post_stream_mode compatibility across all ad types and test suites.
- Replace .widget-connector with .ad-connector for ad placement after posts.
- Migrate initialize-ad-plugin.js to initialize-ad-plugin.gjs to leverage Glimmer and API improvements.
- Use withSilencedDeprecations to handle widget overrides for post ads.
- Update compatibility constraints in .discourse-compatibility.
- Refactor and expand acceptance tests for AdSense, DFP, and House Ads to run with both Glimmer and legacy post stream modes.
2025-07-08 16:28:54 -03:00
David Taylor
e51aad3bfd
DEV: Resolve @on import deprecation (#248) 2025-07-03 22:58:25 +01:00
dependabot[bot]
fcd734079b
Bump rack from 3.1.12 to 3.1.16 (#246)
Bumps [rack](https://github.com/rack/rack) from 3.1.12 to 3.1.16.
- [Release notes](https://github.com/rack/rack/releases)
- [Changelog](https://github.com/rack/rack/blob/main/CHANGELOG.md)
- [Commits](https://github.com/rack/rack/compare/v3.1.12...v3.1.16)

---
updated-dependencies:
- dependency-name: rack
  dependency-version: 3.1.16
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-06-21 17:45:02 +02:00
Jarek Radosz
a98a223a35
DEV: Update linting config and run gjs-codemod 2025-06-05 11:34:48 +01:00
Loïc Guitaut
123dc9e6d8
DEV: Add system spec to check core features are working fine (#242) 2025-04-09 14:19:55 +02:00
Jarek Radosz
2f3916c761
DEV: Update linting (#241) 2025-03-17 10:55:10 +00:00
Jarek Radosz
6a5bfcc782
DEV: Update linting (#240) 2025-03-13 13:25:35 +00:00
dependabot[bot]
32ccafecde
Bump rack from 3.0.11 to 3.0.12 (#237)
Bumps [rack](https://github.com/rack/rack) from 3.0.11 to 3.0.12.
- [Release notes](https://github.com/rack/rack/releases)
- [Changelog](https://github.com/rack/rack/blob/main/CHANGELOG.md)
- [Commits](https://github.com/rack/rack/commits/v3.0.12)

---
updated-dependencies:
- dependency-name: rack
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-13 23:25:11 +00:00
David Taylor
1f70537968
DEV: Bump dependencies and fix linting (#236) 2025-02-06 17:42:21 +01:00
David Taylor
6aab733bb9
DEV: Pin version for Discourse <3.5.0.beta1-dev (#235) 2025-02-05 19:57:37 +01:00
Kelv
6ceba62e98
DEV: Update more deprecated Font Awesome icon names (#233) 2024-12-06 20:44:52 +01:00
David Taylor
44b17146c0
FIX: HouseAdsChooser onChange handling (#234)
Having an action named the same as an argument is no longer possible in a classic component. Move the logic to the parent instead.

Followup to 7685ebf396c93e8accc5a76a81fcec4384a73fa3
2024-12-06 16:02:29 +00:00
Kelv
00298bf01a
DEV: Update deprecated Font Awesome icon names (#232) 2024-12-04 02:38:01 +01:00
David Taylor
7685ebf396
DEV: Update to native class syntax (#230) 2024-11-29 10:11:21 +00:00
David Taylor
4506b0b837
DEV: Update linting (#229) 2024-11-28 15:49:06 +01:00
David Taylor
0400165798
DEV: Update linting (#228) 2024-11-20 18:50:41 +01:00
David Taylor
119d331759
DEV: Update linting (#227) 2024-11-20 15:43:19 +01:00
dependabot[bot]
e28f97a0f4
Bump cross-spawn from 7.0.3 to 7.0.6 (#226)
Bumps [cross-spawn](https://github.com/moxystudio/node-cross-spawn) from 7.0.3 to 7.0.6.
- [Changelog](https://github.com/moxystudio/node-cross-spawn/blob/master/CHANGELOG.md)
- [Commits](https://github.com/moxystudio/node-cross-spawn/compare/v7.0.3...v7.0.6)

---
updated-dependencies:
- dependency-name: cross-spawn
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-11-19 10:37:59 +00:00
David Taylor
1d3baa5519
DEV: Update eslint config (#225) 2024-11-19 11:18:26 +01:00
Discourse Translator Bot
21de3a2b10
Update translations (#224) 2024-10-29 15:31:18 +01:00
dependabot[bot]
c91c456187
Bump rexml from 3.3.6 to 3.3.9 (#223)
Bumps [rexml](https://github.com/ruby/rexml) from 3.3.6 to 3.3.9.
- [Release notes](https://github.com/ruby/rexml/releases)
- [Changelog](https://github.com/ruby/rexml/blob/master/NEWS.md)
- [Commits](https://github.com/ruby/rexml/compare/v3.3.6...v3.3.9)

---
updated-dependencies:
- dependency-name: rexml
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-28 20:43:51 +01:00
Kelv
e42b90507e
DEV: Switch to use pnpm (#222) 2024-10-14 13:37:11 +02:00
dependabot[bot]
38354f2a2f
Bump micromatch from 4.0.5 to 4.0.8 (#221)
Bumps [micromatch](https://github.com/micromatch/micromatch) from 4.0.5 to 4.0.8.
- [Release notes](https://github.com/micromatch/micromatch/releases)
- [Changelog](https://github.com/micromatch/micromatch/blob/master/CHANGELOG.md)
- [Commits](https://github.com/micromatch/micromatch/compare/4.0.5...4.0.8)

---
updated-dependencies:
- dependency-name: micromatch
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-01 12:46:36 +02:00
dependabot[bot]
fc109c75c4
Bump rexml from 3.3.3 to 3.3.6 (#219)
Bumps [rexml](https://github.com/ruby/rexml) from 3.3.3 to 3.3.6.
- [Release notes](https://github.com/ruby/rexml/releases)
- [Changelog](https://github.com/ruby/rexml/blob/master/NEWS.md)
- [Commits](https://github.com/ruby/rexml/compare/v3.3.3...v3.3.6)

---
updated-dependencies:
- dependency-name: rexml
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-01 12:31:59 +02:00
Jarek Radosz
35cc34ab17
DEV: Update ace-editor usage (#220)
AceEditor is now a glimmer component (see: https://github.com/discourse/discourse/pull/28492) and it follows the "data down, actions up" pattern.
2024-08-27 13:53:15 +02:00
Discourse Translator Bot
95993e7d93
Update translations (#218) 2024-08-13 16:30:54 +02:00
dependabot[bot]
10093e0a9f
Bump rexml from 3.2.8 to 3.3.3 (#217)
Bumps [rexml](https://github.com/ruby/rexml) from 3.2.8 to 3.3.3.
- [Release notes](https://github.com/ruby/rexml/releases)
- [Changelog](https://github.com/ruby/rexml/blob/master/NEWS.md)
- [Commits](https://github.com/ruby/rexml/compare/v3.2.8...v3.3.3)

---
updated-dependencies:
- dependency-name: rexml
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-08-05 13:16:47 +02:00
Natalie Tay
02f602236a
DEV: Pin plugin for Discourse < 3.4.0.beta1-dev (#216) 2024-08-02 17:03:18 +08:00
Discourse Translator Bot
da38a4c053
Update translations (#215) 2024-07-31 00:13:50 +02:00
Arpit Jalan
ec53a0d6b8
FIX: add a fix for cases where ad record is not found (#214) 2024-07-05 13:00:18 +05:30
Arpit Jalan
9b72130fdf
FIX: show non-restricted ads instead of not showing ads at all (#213)
In some cases where there were category restricted house ads we were not
showing ads on reload. This commit filter out all the ads that should
not be shown on current page, leaving only allowed ads. So now we'll
show ads on every reload in all the cases.

Internal ticket: t130920
2024-06-27 22:13:54 +05:30
Discourse Translator Bot
a38fbd0935
Update translations (#212) 2024-06-25 15:39:10 +02:00
dependabot[bot]
ea9a0def55
Bump braces from 3.0.2 to 3.0.3 (#211)
Bumps [braces](https://github.com/micromatch/braces) from 3.0.2 to 3.0.3.
- [Changelog](https://github.com/micromatch/braces/blob/master/CHANGELOG.md)
- [Commits](https://github.com/micromatch/braces/compare/3.0.2...3.0.3)

---
updated-dependencies:
- dependency-name: braces
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-06-16 22:30:23 +02:00
Discourse Translator Bot
81843e8c98
Update translations (#210) 2024-06-04 21:43:55 +02:00
Discourse Translator Bot
114639d2e7
Update translations (#209) 2024-05-31 12:26:24 +02:00
Loïc Guitaut
5f1e07c556
DEV: Update rubocop-discourse to version 3.8.0 (#208) 2024-05-28 11:11:14 +02:00
dependabot[bot]
f5c1b6da59
Bump rexml from 3.2.6 to 3.2.8 (#207)
Bumps [rexml](https://github.com/ruby/rexml) from 3.2.6 to 3.2.8.
- [Release notes](https://github.com/ruby/rexml/releases)
- [Changelog](https://github.com/ruby/rexml/blob/master/NEWS.md)
- [Commits](https://github.com/ruby/rexml/compare/v3.2.6...v3.2.8)

---
updated-dependencies:
- dependency-name: rexml
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-16 23:54:19 +02:00
Discourse Translator Bot
6cd52a4966
Update translations (#206) 2024-04-16 17:37:40 +02:00
Isaac Janzen
554f03f3da
FEATURE: Add group and category restrictions to house ads (#205)
# Description

This PR adds the ability to apply **group** and **category** restrictions to a **house ad**.

# What is included
- In order to get the group and category selectors to work within `admin/assets/javascripts/discourse/controllers/admin-plugins-house-ads-show.js` I needed to modernize the file. 
- I dropped the `bufferedProperty` implementation in favor of a vanilla ember approach
- I added `category_ids` and `group_ids` to our house ads model
- I added tests for group / category restrictions
- I added a preview button to display the house ad
- `/site.json` would return a object called `house_creatives` and a list of key value pairs that matched the ad name with the html, like so:
```js
{ AD_KEY: ad.html }
```
I need access to the category ids on the client to conditionally render the house ads so the new format will be: 
```js
{ AD_KEY: { html: ad.html, category_ids: ad.category_ids } }
```

# Screenshots
<img width="658" alt="Screenshot 2024-04-08 at 2 39 22 PM" src="https://github.com/discourse/discourse-adplugin/assets/50783505/b44b386d-65a1-4a2a-a487-d735b13357dd">

# Preview Video

https://github.com/discourse/discourse-adplugin/assets/50783505/6d0d8253-afef-4e15-b6fc-c6f696efd169
2024-04-09 11:54:11 -06:00
Loïc Guitaut
c4227de1b5 DEV: Fix new Rubocop offenses 2024-03-05 18:12:49 +01:00
Selase Krakani
84d9b1a6da
DEV: Pin plugin for Discourse < 3.3.0.beta1-dev (#203) 2024-02-29 13:48:36 -07:00
Discourse Translator Bot
062efc8a54
Update translations (#202) 2024-02-23 09:42:33 +01:00
David Taylor
32f18893ec
FEATURE: Improve DFP / Ad-manager Content-Security-Policy compat (#201)
Switching to cross-domain iframes is recommended by google here: https://developers.google.com/publisher-tag/guides/content-security-policy
2024-02-19 12:35:22 +00:00
Blake Erickson
b0c95114ea
FIX: Calculate no ads for groups server side (#200)
If the selected group to not display ads to had its visibility set to
not be visible then this setting wouldn't work correctly because that
group wouldn't be available client side. The change moves that group
check to be server side so that we can correctly see all the groups that
should not see ads.
2024-02-15 14:52:15 -07:00
David Taylor
1677f7ae39
DEV: Pass post instead of transformedPost to post-bottom-ad (#199)
Changes in 0948d6b19e34320f95226cc43fbce976b71ceb31 caused the post-bottom-ad component to start receiving the widget-ised 'transformedPost' instead of the original `post` model. In most cases this difference didn't matter, but it did cause noticable issues with `@model.category` and `@model.topic`.

This commit also deletes the unused `post-bottom/discourse-adplugin.hbs` connector. In the past, the adplugin itself was defining the post-bottom outlet. But now, we use RenderGlimmer to load the `post-bottom-ad` directly.
2024-02-14 13:59:36 +00:00