Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 2 additions & 2 deletions app/Services/Social/TikTokPublisher.php
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ private function buildVideoPostInfo(PostPlatform $postPlatform, ?string $content
'title' => $content ?? '',
'privacy_level' => $this->resolveRequiredPrivacyLevel($postPlatform),
'disable_duet' => ! data_get($meta, 'allow_duet', false),
'disable_comment' => ! data_get($meta, 'allow_comments', true),
'disable_comment' => ! data_get($meta, 'allow_comments', false),
'disable_stitch' => ! data_get($meta, 'allow_stitch', false),
];

Expand Down Expand Up @@ -142,7 +142,7 @@ private function buildPhotoPostInfo(PostPlatform $postPlatform, ?string $content
$postInfo = [
'description' => $content ?? '',
'privacy_level' => $this->resolveRequiredPrivacyLevel($postPlatform),
'disable_comment' => ! data_get($meta, 'allow_comments', true),
'disable_comment' => ! data_get($meta, 'allow_comments', false),
];

if (data_get($meta, 'brand_content_toggle', false)) {
Expand Down
4 changes: 2 additions & 2 deletions lang/en/posts.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
],
'posting_to' => 'Posting to',
'privacy_level' => 'Who can see this video?',
'privacy_placeholder' => 'Select visibility',
'privacy_placeholder' => 'Select who can view this post',
'privacy' => [
'public' => 'Public to everyone',
'friends' => 'Mutual follow friends',
Expand All @@ -87,7 +87,7 @@
'compliance_incomplete' => 'You need to indicate if your content promotes yourself, a third party, or both.',
'privacy_required' => 'TikTok privacy level is required when publishing.',
'branded_cleared_private' => 'Privacy was cleared because Branded Content cannot be private.',
'interaction_disabled_by_creator' => 'Disabled by your TikTok account settings.',
'interaction_disabled_by_creator' => 'Turned off in your TikTok account settings',
'max_duration_exceeded' => 'Video is :duration s long but this account can only post videos up to :max s.',
'processing_hint' => 'After publishing, it may take a few minutes for the content to process and appear on your TikTok profile.',
'brand_organic' => 'Your brand',
Expand Down
4 changes: 2 additions & 2 deletions lang/es/posts.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
],
'posting_to' => 'Publicando en',
'privacy_level' => '¿Quién puede ver este video?',
'privacy_placeholder' => 'Selecciona la visibilidad',
'privacy_placeholder' => 'Selecciona quién puede ver esta publicación',
'privacy' => [
'public' => 'Público para todos',
'friends' => 'Amigos mutuos',
Expand All @@ -87,7 +87,7 @@
'compliance_incomplete' => 'Debes indicar si tu contenido promociona a ti mismo, a un tercero o a ambos.',
'privacy_required' => 'La visibilidad de TikTok es obligatoria al publicar.',
'branded_cleared_private' => 'La visibilidad se borró porque el contenido de marca no puede ser privado.',
'interaction_disabled_by_creator' => 'Desactivado por la configuración de tu cuenta TikTok.',
'interaction_disabled_by_creator' => 'Desactivado en la configuración de tu cuenta TikTok',
'max_duration_exceeded' => 'El video dura :duration s pero esta cuenta solo permite videos de hasta :max s.',
'processing_hint' => 'Después de publicar, puede tardar unos minutos en procesarse y aparecer en tu perfil de TikTok.',
'brand_organic' => 'Tu marca',
Expand Down
4 changes: 2 additions & 2 deletions lang/pt-BR/posts.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
],
'posting_to' => 'Publicando em',
'privacy_level' => 'Quem pode ver este vídeo?',
'privacy_placeholder' => 'Selecione a visibilidade',
'privacy_placeholder' => 'Selecione quem pode ver este post',
'privacy' => [
'public' => 'Público para todos',
'friends' => 'Amigos em comum',
Expand All @@ -87,7 +87,7 @@
'compliance_incomplete' => 'Você precisa indicar se o conteúdo promove você mesmo, terceiros ou ambos.',
'privacy_required' => 'A visibilidade do TikTok é obrigatória ao publicar.',
'branded_cleared_private' => 'A visibilidade foi limpa porque conteúdo de marca não pode ser privado.',
'interaction_disabled_by_creator' => 'Desativado pelas configurações da sua conta TikTok.',
'interaction_disabled_by_creator' => 'Desativado nas configurações da sua conta TikTok',
'max_duration_exceeded' => 'Vídeo tem :duration s mas esta conta só permite vídeos de até :max s.',
'processing_hint' => 'Após publicar, pode levar alguns minutos para o conteúdo ser processado e aparecer no seu perfil TikTok.',
'brand_organic' => 'Sua marca',
Expand Down
5 changes: 5 additions & 0 deletions resources/js/components/posts/editor/TikTokSettings.vue
Original file line number Diff line number Diff line change
Expand Up @@ -397,6 +397,11 @@ watch(
{{ $t('posts.form.tiktok.compliance.music_usage') }}
</a>
</p>

<!-- Post-publish notice required by TikTok Content Sharing Guidelines -->
<p class="mt-3 text-xs text-muted-foreground">
{{ $t('posts.form.tiktok.processing_hint') }}
</p>
</div>
</div>
</template>
5 changes: 3 additions & 2 deletions tests/Feature/Services/Social/TikTokPublisherTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -605,9 +605,10 @@
$body = json_decode($request->body(), true);
$postInfo = data_get($body, 'post_info');

// privacy_level passes through; toggles use safe defaults (duet/stitch off, comments on).
// privacy_level passes through; all interaction toggles default to OFF to match
// the UI checkbox state (TikTok UX guideline: none should be checked by default).
return $postInfo['privacy_level'] === 'PUBLIC_TO_EVERYONE'
&& $postInfo['disable_comment'] === false
&& $postInfo['disable_comment'] === true
&& $postInfo['disable_duet'] === true
&& $postInfo['disable_stitch'] === true
&& ! isset($postInfo['is_aigc'])
Expand Down
35 changes: 35 additions & 0 deletions tests/Feature/TikTokI18nStringsTest.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
<?php

declare(strict_types=1);

test('tiktok english strings match the wording the app reviewer expects', function () {
expect(__('posts.form.tiktok.privacy_placeholder', [], 'en'))
->toBe('Select who can view this post');

expect(__('posts.form.tiktok.interaction_disabled_by_creator', [], 'en'))
->toBe('Turned off in your TikTok account settings');

expect(__('posts.form.tiktok.processing_hint', [], 'en'))
->toBe('After publishing, it may take a few minutes for the content to process and appear on your TikTok profile.');

expect(__('posts.form.tiktok.compliance_incomplete', [], 'en'))
->toBe('You need to indicate if your content promotes yourself, a third party, or both.');

expect(__('posts.form.tiktok.privacy.private_disabled_branded', [], 'en'))
->toBe('Branded content visibility cannot be set to private.');

expect(__('posts.form.tiktok.promotional_organic_title', [], 'en'))
->toBe('Your photo/video will be labeled as "Promotional content".');

expect(__('posts.form.tiktok.promotional_paid_title', [], 'en'))
->toBe('Your photo/video will be labeled as "Paid partnership".');

expect(__('posts.form.tiktok.compliance.agree', [], 'en'))
->toBe("By posting, you agree to TikTok's");

expect(__('posts.form.tiktok.compliance.music_usage', [], 'en'))
->toBe('Music Usage Confirmation');

expect(__('posts.form.tiktok.compliance.branded_policy', [], 'en'))
->toBe('Branded Content Policy');
});
Loading