Skip to content

Commit

Permalink
chore: release xillio-transcreate (#3039)
Browse files Browse the repository at this point in the history
  • Loading branch information
ghuisma authored Sep 25, 2024
1 parent 3e177ab commit 6f16f28
Show file tree
Hide file tree
Showing 198 changed files with 17,000 additions and 15,633 deletions.
3 changes: 2 additions & 1 deletion apps/xillio-transcreate/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,11 @@

# testing
/coverage
/storybook-static

# production
/dist
!/types/dist
.env

# misc
.DS_Store
Expand Down
33 changes: 17 additions & 16 deletions apps/xillio-transcreate/.storybook/main.ts
Original file line number Diff line number Diff line change
@@ -1,27 +1,28 @@
import type { StorybookConfig } from "@storybook/react-vite";
import type { StorybookConfig } from '@storybook/react-vite';

import { join, dirname } from "path";
import { join, dirname } from 'path';

/**
* This function is used to resolve the absolute path of a package.
* It is needed in projects that use Yarn PnP or are set up within a monorepo.
*/
function getAbsolutePath(value: string): any {
return dirname(require.resolve(join(value, "package.json")));
return dirname(require.resolve(join(value, 'package.json')));
}
const config: StorybookConfig = {
stories: ["../src/**/*.mdx", "../src/**/*.stories.@(js|jsx|mjs|ts|tsx)"],
addons: [
getAbsolutePath("@storybook/addon-links"),
getAbsolutePath("@storybook/addon-essentials"),
getAbsolutePath("@storybook/addon-interactions"),
],
framework: {
name: getAbsolutePath("@storybook/react-vite"),
options: {},
},
docs: {
autodocs: "tag",
},
stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|mjs|ts|tsx)'],

addons: [getAbsolutePath('@storybook/addon-links'), getAbsolutePath('@storybook/addon-essentials'), getAbsolutePath('@storybook/addon-interactions')],

framework: {
name: getAbsolutePath('@storybook/react-vite'),
options: {},
},

docs: {},

typescript: {
reactDocgen: 'react-docgen-typescript',
},
};
export default config;
15 changes: 0 additions & 15 deletions apps/xillio-transcreate/.storybook/preview.ts

This file was deleted.

38 changes: 38 additions & 0 deletions apps/xillio-transcreate/.storybook/preview.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
import React from 'react';

import type { Preview } from '@storybook/react';

import { Box, GlobalStyles } from '@contentful/f36-components';
import tokens from '@contentful/f36-tokens';
import { css } from 'emotion';

const preview: Preview = {
parameters: {
controls: {
matchers: {
color: /(background|color)$/i,
date: /Date$/,
},
include: [],
},
},

decorators: [
(Story) => (
<>
<GlobalStyles />
<Box
padding="spacingL"
className={css({
backgroundColor: tokens.gray100,
position: 'fixed',
inset: 0,
})}>
<Story />
</Box>
</>
),
],
};

export default preview;
9 changes: 3 additions & 6 deletions apps/xillio-transcreate/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,18 @@

## [1.0.2](https://github.com/contentful/marketplace-partner-apps/compare/xillio-transcreate-v1.0.1...xillio-transcreate-v1.0.2) (2024-09-03)


### Bug Fixes

* **deps:** bump react-hook-form from 7.52.0 to 7.52.2 ([#2617](https://github.com/contentful/marketplace-partner-apps/issues/2617)) ([35fb795](https://github.com/contentful/marketplace-partner-apps/commit/35fb79503eeae20e557c7490f598c3422f29574f))
- **deps:** bump react-hook-form from 7.52.0 to 7.52.2 ([#2617](https://github.com/contentful/marketplace-partner-apps/issues/2617)) ([35fb795](https://github.com/contentful/marketplace-partner-apps/commit/35fb79503eeae20e557c7490f598c3422f29574f))

## [1.0.1](https://github.com/contentful/marketplace-partner-apps/compare/xillio-transcreate-v1.0.0...xillio-transcreate-v1.0.1) (2024-07-02)


### Bug Fixes

* **deps:** bump react-hook-form from 7.51.3 to 7.52.0 ([#2189](https://github.com/contentful/marketplace-partner-apps/issues/2189)) ([d254443](https://github.com/contentful/marketplace-partner-apps/commit/d254443adc505caac3aa834db939a0bbee413945))
- **deps:** bump react-hook-form from 7.51.3 to 7.52.0 ([#2189](https://github.com/contentful/marketplace-partner-apps/issues/2189)) ([d254443](https://github.com/contentful/marketplace-partner-apps/commit/d254443adc505caac3aa834db939a0bbee413945))

## 1.0.0 (2024-05-30)


### Features

* Xillio Transcreate App ([#1318](https://github.com/contentful/marketplace-partner-apps/issues/1318)) ([e938eab](https://github.com/contentful/marketplace-partner-apps/commit/e938eabc902fb43efedb1220dfecd092ac5c4ced))
- Xillio Transcreate App ([#1318](https://github.com/contentful/marketplace-partner-apps/issues/1318)) ([e938eab](https://github.com/contentful/marketplace-partner-apps/commit/e938eabc902fb43efedb1220dfecd092ac5c4ced))
20 changes: 19 additions & 1 deletion apps/xillio-transcreate/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

The Xillio Transcreate Contentful App brings the power of professional translation services directly into the heart of your Contentful workflow. Translate your content efficiently and seamlessly, ensuring that your multilingual projects are delivered with quality and consistency.

For full information about the app, see the Xillio Transcreate documentation [here](https://docs.xillio.com/transcreate)
For full information about the app, see the Xillio Transcreate documentation [here](https://docs.xill.io/transcreate)

## Available Scripts

Expand Down Expand Up @@ -41,3 +41,21 @@ For this command to work, the following environment variables must be set:
- `CONTENTFUL_ORG_ID` - The ID of your organization
- `CONTENTFUL_APP_DEF_ID` - The ID of the app to which to add the bundle
- `CONTENTFUL_ACCESS_TOKEN` - A personal [access token](https://www.contentful.com/developers/docs/references/content-management-api/#/reference/personal-access-tokens)

#### `npm run storybook`

This command starts the Storybook development server, allowing you to view and interact with your app's components in isolation. Storybook is a popular tool for developing UI components in isolation and documenting their behavior.

#### `npm run test:storybook`

This command is used to run the Storybook test suite for the Xillio Transcreate app.

Before running the tests, make sure to run `npm run storybook` and have an active Storybook instance running on port 6006.

#### `npm run test`

This command is used to run the tests for the Xillio Transcreate app.

It can be ran locally, but is intented to be used on a CI server to automate the testing process.

The command makes a static build of Storybook and runs these headless using Playwright.
37 changes: 37 additions & 0 deletions apps/xillio-transcreate/eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
import js from '@eslint/js';
import globals from 'globals';
import reactHooks from 'eslint-plugin-react-hooks';
import tseslint from 'typescript-eslint';

export default tseslint.config(
{ ignores: ['dist', '.storybook', 'storybook-static'] },
{
extends: [js.configs.recommended, ...tseslint.configs.recommended],
files: ['**/*.{ts,tsx}'],
languageOptions: {
ecmaVersion: 2020,
globals: globals.browser,
},
plugins: {
'react-hooks': reactHooks,
},
rules: {
...reactHooks.configs.recommended.rules,
'@typescript-eslint/no-explicit-any': 'off',
'@typescript-eslint/no-unused-vars': [
'error',
{
argsIgnorePattern: '^_',
varsIgnorePattern: '^_',
caughtErrorsIgnorePattern: '^_',
},
],
},
},
{
files: ['**/*.stories.tsx'],
rules: {
'react-hooks/rules-of-hooks': 'off',
},
},
);
18 changes: 9 additions & 9 deletions apps/xillio-transcreate/index.html
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
</head>
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
</head>

<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
<script type="module" src="/src/index.tsx"></script>
</body>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
<script type="module" src="/src/index.tsx"></script>
</body>
</html>
Loading

0 comments on commit 6f16f28

Please sign in to comment.