Skip to content

Commit

Permalink
adjust text
Browse files Browse the repository at this point in the history
  • Loading branch information
GrabowskiM committed Oct 25, 2023
1 parent 85bb41f commit 59b316f
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 13 deletions.
2 changes: 1 addition & 1 deletion features/standard/Autosave.feature
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ Feature: Content Items creation
| label | value |
| Title | Test Article Autosave Off draft |
| Short title | Test Article Autosave Off draft |
And I check if "Autosave is off" notification is displayed
And I check if "Autosave is off, draft not created" notification is displayed
And I open the "Dashboard" page in admin SiteAccess
Then there's no draft "Test Article Autosave Off draft" on Dashboard list

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@
const saveDate = ibexa.helpers.timezone.convertDateToTimezone(new Date(), userPreferredTimezone);
const saveTime = moment(saveDate).formatICU('HH:mm');
const saveMessage = Translator.trans(
/*@Desc("Draft saved %time%")*/ 'content_edit.autosave.status_saved.message.full',
/*@Desc("Autosave is on, draft created %time%")*/ 'content_edit.autosave.status_saved.message.full',
{ time: saveTime },
'ibexa_content',
);
Expand Down
4 changes: 2 additions & 2 deletions src/bundle/Resources/translations/ibexa_content.en.xliff
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@
<note>key: content.reveal.success</note>
</trans-unit>
<trans-unit id="123a6cff0d98d08927f6666246d451da50941a7b" resname="content_edit.autosave.status_saved.message.full">
<source>Draft saved %time%</source>
<target state="new">Draft saved %time%</target>
<source>Autosave is on, draft created %time%</source>
<target state="new">Autosave is on, draft created %time%</target>
<note>key: content_edit.autosave.status_saved.message.full</note>
</trans-unit>
<trans-unit id="750bead6705b295c7b7d66c27b2768c1b9329ed5" resname="editing_details">
Expand Down
8 changes: 4 additions & 4 deletions src/bundle/Resources/translations/messages.en.xliff
Original file line number Diff line number Diff line change
Expand Up @@ -187,13 +187,13 @@
<note>key: content_edit.autosave.status_error.message</note>
</trans-unit>
<trans-unit id="d364f97b275523fe571da0da612fdbc4a1064550" resname="content_edit.autosave.status_off.message">
<source>Autosave is off</source>
<target state="new">Autosave is off</target>
<source>Autosave is off, draft not created</source>
<target state="new">Autosave is off, draft not created</target>
<note>key: content_edit.autosave.status_off.message</note>
</trans-unit>
<trans-unit id="93f0a5980aa14af989f4106ffda244ba02db1c32" resname="content_edit.autosave.status_on.message">
<source>Autosave is on</source>
<target state="new">Autosave is on</target>
<source>Autosave is on, draft created %time%</source>
<target state="new">Autosave is on, draft created %time%</target>
<note>key: content_edit.autosave.status_on.message</note>
</trans-unit>
<trans-unit id="da43c85269df161b340e92296642e18ec6af033e" resname="content_edit.autosave.status_saving.message">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,12 @@
{{ 'content_edit.autosave.status_error.message'|trans()|desc('Saving error') }}
</div>
<div class="ibexa-autosave__status-off">
{{ 'content_edit.autosave.status_off.message'|trans()|desc('Autosave is off') }}
{{ 'content_edit.autosave.status_off.message'|trans()|desc('Autosave is off, draft not created') }}
</div>
<div class="ibexa-autosave__status-on">
{{ 'content_edit.autosave.status_on.message'|trans()|desc('Autosave is on') }}
{% set current_time = 'now'|date('H:i', ibexa_user_settings.timezone) %}

{{ 'content_edit.autosave.status_on.message'|trans({ '%time%': current_time })|desc('Autosave is on, draft created %time%') }}
</div>
<div class="ibexa-autosave__status-saved"></div>
<div class="ibexa-autosave__status-saving">
Expand Down
2 changes: 1 addition & 1 deletion src/lib/Behat/BrowserContext/ContentUpdateContext.php
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ public function iWaitForAutosaveNotification(): void
}

/**
* @When I check if "Autosave is off" notification is displayed
* @When I check if "Autosave is off, draft not created" notification is displayed
*/
public function iCheckAutosaveNotification(): void
{
Expand Down
4 changes: 2 additions & 2 deletions src/lib/Behat/Page/ContentUpdateItemPage.php
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ public function verifyAutosaveNotificationIsDisplayed(): void
{
$this->getHTMLPage()
->find($this->getLocator('autosaveIsOnInfo'))
->assert()->textContains('Autosave is on');
->assert()->textContains('Autosave is on, draft created');
}

public function verifyAutosaveDraftIsSavedNotificationIsDisplayed(): void
Expand Down Expand Up @@ -284,6 +284,6 @@ public function verifyAutosaveIsOffNotificationIsDisplayed(): void
{
$this->getHTMLPage()
->find($this->getLocator('autosaveIsOffInfo'))
->assert()->textContains('Autosave is off');
->assert()->textContains('Autosave is off, draft not created');
}
}

0 comments on commit 59b316f

Please sign in to comment.