This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
input <%= association %>InlineInput { | |
connect: <%= association %>UniqueIdInput | |
create: <%= association %>CreateInput | |
createOrUpdate: <%= association %>CreateOrUpdateInlineInput | |
# Update-only. Should these be in a separate type? | |
update: <%= association %>UpdateInlineInput | |
disconnect: Boolean | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# applies to published revision only | |
"slug_prefix" | |
"comments_closed" | |
"comments_auto_closed_at" | |
# applies to draft revision only / story editor metadata | |
"hidden" | |
"embargoed" | |
"publish_scheduled_for" | |
"trashed_at" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
interface EntryRevision { | |
title: String | |
body: EntryBody | |
# etc | |
} | |
# A published unit of content | |
type Entry implements EntryRevision { | |
draft: EntryDraft | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
query { | |
entryBody(uuid: "b4c7210f-0593-4ab2-85d9-abab343fcc09") { | |
components { | |
blockquote { | |
paragraphs { | |
ops | |
} | |
} | |
grouping { | |
layout |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function eachHardLine(delta, fn) { | |
let buffer = new Delta(); | |
new Delta(delta).eachLine((line, attributes) => { | |
buffer = buffer.concat(line); | |
if (attributes.br) { | |
buffer.insert('\n', attributes); | |
} else { | |
fn(buffer, attributes); | |
buffer = new Delta(); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ | |
"type": "EntryBodyParagraphComponent", | |
"ops": [ | |
{ | |
"insert": "a man ", | |
"attributes": {} | |
}, | |
{ | |
"insert": "a plan", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/test/chorus_auth_client_test.rb b/test/chorus_auth_client_test.rb | |
index c383a1528b8f..377455808ea5 100644 | |
--- a/test/chorus_auth_client_test.rb | |
+++ b/test/chorus_auth_client_test.rb | |
@@ -104,7 +104,8 @@ class ChorusAuthClientTest < Minitest::Test | |
end | |
def test_decode_jwt! | |
- VCR.use_cassette('decode_jwt') do | |
+ stub_request(:get, 'https://chorus-development.auth0.com/.well-known/jwks.json') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class ApiClient { | |
constructor(jwt) { | |
// parse + verify jwt | |
// set properties based on jwt claims | |
} | |
user() { | |
if (this.user_id) { | |
return towerRequest(USER_INFO, { user_id: this.user_id }); | |
} else { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type EntryBody { | |
components: [EntryBodyComponent] | |
} | |
# all components have a plaintext and an html representation | |
interface EntryBodyComponent { | |
plaintext: String | |
html: String | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| | draft story | pub'd story | | |
-------------------------------------------- | |
| draft stream | NO | YES | | |
| pub'd stream | YES | YES | | |
This implies: | |
A draft stream can only contain pub'd stories | |
A draft story can only contain pub'd streams | |
NewerOlder