• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

EcrituresNumeriques / stylo / 14591529118

22 Apr 2025 09:33AM UTC coverage: 23.1%. First build
14591529118

Pull #1438

github

web-flow
Merge daa7f557e into 4cab56d65
Pull Request #1438: fix: récupère et affiche la date de création de la version

319 of 519 branches covered (61.46%)

Branch coverage included in aggregate %.

0 of 5 new or added lines in 2 files covered. (0.0%)

2611 of 12165 relevant lines covered (21.46%)

2.5 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/front/src/components/collaborative/CollaborativeEditorActiveVersion.jsx
1
import React from 'react'
×
2

3
import { useArticleVersion } from '../../hooks/article.js'
×
4
import i18n from '../../i18n.js'
×
5

6
import Alert from '../molecules/Alert.jsx'
×
7
import Loading from '../molecules/Loading.jsx'
×
8

9
export default function CollaborativeEditorActiveVersion({ versionId }) {
×
10
  const { version, isLoading, error } = useArticleVersion({ versionId })
×
11

12
  if (isLoading) {
×
13
    return <Loading />
×
14
  }
×
15

16
  if (error) {
×
17
    return <Alert versionId={error.message()} />
×
18
  }
×
19

20
  if (versionId && version) {
×
21
    const versionNumber = `${version.version}.${version.revision}`
×
22
    const versionCodename =
×
23
      version.message.trim().length > 0 ? `"${version.message}"` : null
×
24
    const versionDate = new Intl.DateTimeFormat(i18n.language, {
×
25
      dateStyle: 'full',
×
26
      timeStyle: 'long',
×
NEW
27
    }).format(new Date(version.createdAt))
×
28
    return (
×
29
      <Alert
×
30
        type="info"
×
31
        message={`Vous êtes sur la version ${versionNumber}${
×
32
          versionCodename ? ` ${versionCodename}` : ''
×
33
        } du ${versionDate}`}
×
34
      ></Alert>
×
35
    )
36
  }
×
37

38
  return (
×
39
    <Alert type="info" message={`Vous êtes sur la copie de travail`}></Alert>
×
40
  )
41
}
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc