Compare commits

...

42 Commits

Author SHA1 Message Date
Basti 48822cc0b1
WIP create invites via API 2019-03-09 09:18:53 +07:00
Basti 582b1423c8 Merge tag 'v2.7.0' into kosmos 2019-01-27 10:26:58 +08:00
Basti 1b3bac997d Fix background style 2018-10-31 23:10:39 +01:00
Basti c7697ad5f4 Merge tag 'v2.6.1' into kosmos 2018-10-31 22:10:00 +01:00
Basti ebdf94e346 Revert "Skip incompatible migration entirely"
This reverts commit 545eb6385d.
2018-10-31 22:09:43 +01:00
Basti 545eb6385d Skip incompatible migration entirely 2018-09-03 21:26:36 +08:00
Basti 18c4e7ecb1 Revert "Prevent upsert operation"
This reverts commit 641ecd4677.
2018-09-03 21:09:01 +08:00
Basti 641ecd4677 Prevent upsert operation
Only works in newer postgresql, but also not really necessary because
the table is brandnew there.
2018-09-03 20:43:38 +08:00
Basti 35dc6c095a Merge tag 'v2.5.0' into kosmos 2018-09-03 19:36:47 +08:00
Basti 65beeb044d Merge tag 'v2.4.5' into kosmos 2018-08-26 16:40:40 +02:00
Basti 8a86cd15cb Merge tag 'v2.4.4' into kosmos 2018-08-26 16:11:40 +02:00
Eugen Rochko add3b63a0c Bump version to 2.4.5 2018-08-24 20:11:40 +02:00
Eugen Rochko 221c8c771f Prevent ActivityPub movedTo recursion (#8092)
Fix #8051
2018-08-24 20:11:16 +02:00
ThibG a16d41e9fb Fix FixAccountsUniqueIndex migration (#8212) 2018-08-24 20:10:18 +02:00
ThibG f6ad5edbaa Make some migration script more robust (fixes #8007) (#8170)
Include a dummy Account class in the migration script containing only the
attributes relevant to the migration in order to not rely as much on the
codebase being in sync with the database schema.
2018-08-24 20:09:57 +02:00
Akihiko Odaki 3f4812c583 Fix index detection a migration to revert index change (#8026) 2018-08-24 20:09:13 +02:00
Eugen Rochko 86792bd309 Upgrade Doorkeeper to 5.0.0 (#8409)
See doorkeeper-gem/doorkeeper#1137
2018-08-24 20:06:50 +02:00
Eugen Rochko 612d02028c Bump version to 2.4.4 2018-08-22 20:56:43 +02:00
Eugen Rochko f100e84372 Improve federated ID validation (#8372)
* Fix URI not being sufficiently validated with prefetched JSON

* Add additional id validation to OStatus documents, when possible
2018-08-22 20:56:26 +02:00
ThibG 31a209cb01 Upgrade doorkeeper to 4.4.2 (#8321) 2018-08-22 19:31:27 +02:00
Eugen Rochko 13a062a5d9 Upgrade Doorkeeper to 4.4.1 (#8197) 2018-08-22 19:30:02 +02:00
Basti e9606628f0 Merge tag 'v2.4.3' into kosmos 2018-07-17 17:30:35 +02:00
Basti f1cd068781 Merge tag 'v2.4.2' into kosmos 2018-06-22 14:30:48 -07:00
Basti 4b0a895846 Merge tag 'v2.4.1' into kosmos 2018-06-10 19:56:53 +02:00
Basti d7ffa77545 Fixed background on about page 2018-05-24 20:24:07 +02:00
Basti 3dccf8bab9 Merge tag 'v2.4.0' into kosmos 2018-05-23 11:30:36 +02:00
Basti 818a285769 Merge tag 'v2.3.2' into kosmos 2018-05-08 15:32:18 +02:00
Basti 1fe1cf1cf2 Merge tag 'v2.2.0' into kosmos 2018-01-30 11:34:16 +00:00
Basti e89ade266a Merge tag 'v2.1.3' into kosmos 2018-01-13 14:07:04 +00:00
Basti 42cea8a076 Merge tag 'v2.1.2' into kosmos 2018-01-09 19:54:13 +00:00
Basti 9b7b1fbf35 Call our users kosmonauts on about page 2017-12-20 10:45:34 +00:00
Basti 6d1b204b6a Merge branch 'master' into kosmos 2017-12-20 10:15:42 +00:00
Basti 5091739526 Re-enable custom styles 2017-10-28 23:04:15 +02:00
Basti 63e288ed6f Merge tag 'v2.0.0' into kosmos 2017-10-28 22:51:56 +02:00
Basti 65d025267c Merge tag 'v1.6.1' into kosmos 2017-09-19 18:43:12 +02:00
Basti 560a7b602d Merge branch 'master' into kosmos 2017-09-10 17:12:34 +02:00
Basti 6d1295c0e6 Merge tag 'v1.5.0' into kosmos 2017-08-01 17:30:25 +02:00
Basti 1388d73e0c Merge tag 'v1.5.0rc3' into kosmos 2017-08-01 12:56:22 +02:00
Basti 3704f3ccb3 Merge tag 'v1.5.0rc2' into kosmos 2017-07-29 10:10:15 +02:00
Basti 0b4a382151 Adjust styles for new frontpage 2017-07-27 11:09:31 +02:00
Basti ba1b8a5a11 Merge branch 'master' into kosmos 2017-07-27 10:46:36 +02:00
Basti 4c3a7ebcca Customize styles 2017-06-16 11:17:28 -07:00
8 changed files with 70 additions and 3 deletions

View File

@ -0,0 +1,18 @@
# frozen_string_literal: true
class Api::V1::InvitesController < Api::BaseController
before_action -> { doorkeeper_authorize! :write, :'write:accounts' }
before_action :require_user!
respond_to :json
def create
@invite = Invite.new(max_uses: 1)
@invite.user = current_user
@invite.save!
render json: @invite, serializer: REST::InviteSerializer
end
end

Binary file not shown.

After

Width:  |  Height:  |  Size: 124 KiB

View File

@ -0,0 +1,26 @@
@import 'application';
body {
background-color: $ui-base-color;
background-image: url('../images/background-kosmos.jpg');
background-size: cover;
background-attachment: fixed;
}
body.about-body {
background-color: transparent;
background-image: url('../images/background-kosmos.jpg');
background-size: cover;
background-attachment: fixed;
}
.landing-page .learn-more-cta {
background: rgba(31,35,43,0.5);
}
.ui {
background-color: darken($ui-base-color, 7%);
background-image: url('../images/background-kosmos.jpg');
background-size: cover;
background-attachment: fixed;
}

View File

@ -0,0 +1,21 @@
# frozen_string_literal: true
class REST::InviteSerializer < ActiveModel::Serializer
attributes :id, :code, :expires_at, :max_uses
def id
object.id.to_s
end
def code
object.code
end
def expires_at
object.expires_at
end
def max_uses
object.max_uses
end
end

View File

@ -36,8 +36,8 @@ en:
status_count_before: Who authored
terms: Terms of service
user_count_after:
one: user
other: users
one: kosmonaut
other: kosmonauts
user_count_before: Home to
what_is_mastodon: What is Mastodon?
accounts:

View File

@ -297,6 +297,7 @@ Rails.application.routes.draw do
resources :reports, only: [:create]
resources :filters, only: [:index, :create, :show, :update, :destroy]
resources :endorsements, only: [:index]
resources :invites, only: [:create]
namespace :apps do
get :verify_credentials, to: 'credentials#show'

View File

@ -1,3 +1,3 @@
default: styles/application.scss
default: styles/custom.scss
contrast: styles/contrast.scss
mastodon-light: styles/mastodon-light.scss

View File

@ -351,6 +351,7 @@ ActiveRecord::Schema.define(version: 2019_01_17_114553) do
t.boolean "silent", default: false, null: false
t.index ["account_id", "status_id"], name: "index_mentions_on_account_id_and_status_id", unique: true
t.index ["status_id"], name: "index_mentions_on_status_id"
t.index ["status_id"], name: "mentions_status_id_index"
end
create_table "mutes", force: :cascade do |t|