Skip to content
Merged
Show file tree
Hide file tree
Changes from 21 commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
d4530d0
[E] Remove twitter/facebook components + fields from admin
1aurend Feb 27, 2025
e746521
[E] Remove twitter/facebook components from frontend
1aurend Feb 27, 2025
56c34f9
[E] Remove social share buttons from annotation pop up
1aurend Feb 27, 2025
7390f4d
[E] Remove global twitter/facebook components
1aurend Feb 27, 2025
f46dcb1
[C] Remove twitter api helpers
1aurend Feb 27, 2025
1c80459
[C] Remove relevant i18n keys
1aurend Feb 28, 2025
f5ed334
[E] Filter tweet events from api responses
1aurend Feb 28, 2025
cd759c3
[C] Remove tweet event components
1aurend Feb 28, 2025
d55fca5
[C] Remove instagram icons + misc
1aurend Feb 28, 2025
d710461
[F] Implement native share on resource detail
1aurend Mar 3, 2025
34cc409
[B] Add guard to FrontendModeContainer
1aurend Mar 3, 2025
e3d6a9f
[F] Add native share button to reader popup
1aurend Mar 4, 2025
efa2f90
[F] Add copy selection url to reader popup
1aurend Mar 4, 2025
05e1809
[C] Remove twitter/facebook attributes from serializers
1aurend Mar 4, 2025
89a1ce8
[C] Remove twitter query routes
1aurend Mar 4, 2025
57061f2
[C] Remove twitter query controllers
1aurend Mar 4, 2025
0a08d1c
[E] Add styles for ::target-text
1aurend Mar 4, 2025
d765538
[C] Remove twitter_queries from journal issue includes
1aurend Mar 5, 2025
63f14c3
[B] Ensure code editor has a mode
1aurend Mar 5, 2025
20a112f
[B] Reduce clickable area in next section link
1aurend Mar 5, 2025
c836923
[C] Copy fragment utils; remove npm package
1aurend Mar 5, 2025
60b5b33
[C] Remove log
1aurend Mar 6, 2025
23d86a6
[E] Include text fragment in share links
1aurend Mar 6, 2025
753f7b7
[E] Use page title as share title
1aurend Mar 6, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion api/app/controllers/api/v1/journal_issues_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def includes
[:journal, :journal_volume, :project, "project.creators", "project.contributors",
"project.texts", "project.text_categories", "project.events",
"project.resource_collections", "project.resources", "project.subjects",
"project.twitter_queries", "project.permitted_users", "project.content_blocks",
"project.permitted_users", "project.content_blocks",
"project.action_callouts"]
end

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,13 @@ class EventsController < AbstractProjectChildController
resourceful! Event, authorize_options: { except: [:index] } do
Event.filtered(
with_pagination!(event_filter_params),
scope: @project.events.excluding_type([EventType[:comment_created],
EventType[:text_annotated]])
scope: @project.events.excluding_type(
[
EventType[:comment_created],
EventType[:text_annotated],
EventType[:tweet]
]
)
)
end

Expand Down

This file was deleted.

2 changes: 1 addition & 1 deletion api/app/controllers/api/v1/projects_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ def destroy

def includes
[:creators, :contributors, :texts, :text_categories, :events,
:resource_collections, :resources, :subjects, :twitter_queries,
:resource_collections, :resources, :subjects,
:permitted_users, :content_blocks, :action_callouts, :journal,
:journal_volume, :journal_issue, :flattened_collaborators, :collaborators]
end
Expand Down

This file was deleted.

2 changes: 1 addition & 1 deletion api/app/models/project.rb
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ def resources_for_project_detail_ids
end

def filtered_events
events.excluding_type(%w(comment_created text_annotated))
events.excluding_type(%w(comment_created text_annotated tweet))
end

def filtered_event_count
Expand Down
6 changes: 1 addition & 5 deletions api/app/serializers/v1/concerns/project_serializer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,6 @@ module ProjectSerializer
typed_attribute :purchase_price_currency, Types::String.optional.meta(example: "USD")
typed_attribute :purchase_price, Types::Float.optional.meta(read_only: true)
typed_attribute :purchase_call_to_action, Types::String.optional
typed_attribute :twitter_id, Types::String.optional
typed_attribute :instagram_id, Types::String.optional
typed_attribute :facebook_id, Types::String.optional
typed_attribute :description_formatted, Types::String.meta(read_only: true)
typed_attribute :resource_kinds, Types::Array.of(Types::String).meta(read_only: true)
typed_attribute :dark_mode, Types::Bool
Expand Down Expand Up @@ -104,7 +101,6 @@ module ProjectSerializer
id_method_name: :resources_for_project_detail_ids,
object_method_name: :resources_for_project_detail
typed_has_many :subjects
typed_has_many :twitter_queries
typed_has_many :permitted_users, serializer: ::V1::UserSerializer
typed_has_many :content_blocks, polymorphic: true
typed_has_many :action_callouts
Expand Down Expand Up @@ -136,7 +132,7 @@ module ProjectSerializer

class_methods do
def filtered_events(project)
project.events.excluding_type(%w(comment_created text_annotated))
project.events.excluding_type(%w(comment_created text_annotated tweet))
end
end
end
Expand Down
3 changes: 0 additions & 3 deletions api/app/serializers/v1/journal_serializer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,6 @@ class JournalSerializer < ManifoldSerializer
when_full do
metadata(metadata: true, properties: true, formatted: true)
typed_attribute :hashtag, Types::String.optional
typed_attribute :twitter_id, Types::String.optional
typed_attribute :instagram_id, Types::String.optional
typed_attribute :facebook_id, Types::String.optional
typed_attribute :image_credits, Types::String.optional
typed_attribute :image_credits_formatted, Types::String.meta(read_only: true)
typed_attribute :pending_slug, Types::String
Expand Down
16 changes: 3 additions & 13 deletions api/app/serializers/v1/setting_serializer.rb
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,10 @@ class SettingSerializer < ManifoldSerializer
default_project_sort: Types::String.optional,
default_publisher: Types::String.optional,
default_publisher_place: Types::String.optional,
facebook: Types::String.optional,
home_redirect_url: Types::String.optional,
library_redirect_url: Types::String.optional,
press_site: Types::String.optional,
terms_url: Types::Serializer::URL.optional,
twitter: Types::String.optional
terms_url: Types::Serializer::URL.optional
)

typed_section_attribute :ingestion, Types::Hash.schema(
Expand Down Expand Up @@ -74,14 +72,11 @@ class SettingSerializer < ManifoldSerializer
typed_attribute :string_cookies_banner_copy_formatted, Types::String.meta(read_only: true)

typed_section_attribute :integrations, Types::Hash.schema(
facebook_app_id: Types::String.optional,
ga_four_tracking_id: Types::String.optional,
google_client_email: Types::String.optional,
google_client_id: Types::String.optional,
google_private_key_id: Types::String.optional,
google_project_id: Types::String.optional,
twitter_access_token: Types::String.optional,
twitter_app_id: Types::String.optional
google_project_id: Types::String.optional
)

typed_section_attribute :email, Types::Hash.schema(
Expand Down Expand Up @@ -133,18 +128,13 @@ class SettingSerializer < ManifoldSerializer
end

typed_attribute :oauth, Types::Hash.schema(
facebook: Types::Serializer::Oauth,
googleOauth2: Types::Serializer::Oauth,
twitter: Types::Serializer::Oauth
googleOauth2: Types::Serializer::Oauth
).meta(read_only: true) do |_object, _params|
ManifoldEnv.oauth.as_json
end

typed_section_attribute :secrets, Types::Hash.schema(
akismet_api_key: Types::String,
facebook_app_secret: Types::String,
twitter_app_secret: Types::String,
twitter_access_token_secret: Types::String,
google_private_key: Types::String,
smtp_settings_password: Types::String
)
Expand Down
9 changes: 0 additions & 9 deletions api/config/routes.rb
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,6 @@
resources :resources, only: [:index, :create]
resources :resource_collections, only: [:index, :create]
resources :events, only: [:index]
resources :twitter_queries, only: [:index, :create]
resources :resource_imports, only: [:create, :update, :show]
resources :collaborators, only: [:index, :show] do
collection do
Expand All @@ -233,14 +232,6 @@
end
end

resources :twitter_queries, only: [:show, :update, :destroy], controller: "projects/relationships/twitter_queries" do
scope module: :twitter_queries do
namespace :relationships do
resource :fetch, controller: "twitter_query_fetch", only: [:create]
end
end
end

resources :tokens, only: [:create]

resources :users do
Expand Down
1 change: 0 additions & 1 deletion api/spec/requests/api/v1/projects_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
:resource_collections,
:resources,
:subjects,
:twitter_queries,
:permitted_users,
:content_blocks,
:action_callouts
Expand Down
52 changes: 0 additions & 52 deletions api/spec/requests/api/v1/twitter_queries_spec.rb

This file was deleted.

Loading