Skip to content

Commit

Permalink
Fix conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
soupette committed Jan 13, 2020
2 parents 52d25be + 648296c commit bfe37c7
Show file tree
Hide file tree
Showing 108 changed files with 1,586 additions and 505 deletions.
11 changes: 10 additions & 1 deletion .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ module.exports = {

'prettier',
],
plugins: ['react', 'redux-saga', 'react-hooks'],
plugins: ['react', 'redux-saga', 'react-hooks', 'import'],
env: {
browser: true,
commonjs: true,
Expand Down Expand Up @@ -51,4 +51,13 @@ module.exports = {
version: '16.5.2',
},
},
overrides: [
{
files: ['packages/**/admin/src/**/**/*.js'],
rules: {
'no-nested-ternary': ['error'],
'import/order': 2,
},
},
],
};
2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2015-2019 Strapi Solutions.
Copyright (c) 2015-2020 Strapi Solutions.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -134,4 +134,4 @@ Check out our [roadmap](https://portal.productboard.com/strapi) to get informed

## License

[MIT License](LICENSE.md) Copyright (c) 2015-2019 [Strapi Solutions](https://strapi.io/).
[MIT License](LICENSE.md) Copyright (c) 2015-2020 [Strapi Solutions](https://strapi.io/).
2 changes: 1 addition & 1 deletion docs/3.0.0-beta.x/guides/auth-request.md
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ To do so, you will have to request the `/articles` route in **POST**.
import axios from 'axios';

const {data} = await axios
.get('http://localhost:1337/articles', {
.post('http://localhost:1337/articles', {
data: {
title: 'my article'
content: 'my super article content'
Expand Down
28 changes: 26 additions & 2 deletions docs/3.0.0-beta.x/guides/deployment.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,10 @@ NODE_ENV=production npm run build
```bash
npm install cross-env
```

Then in your `package.json` scripts section:
```bash

```bash
"production": "cross-env NODE_ENV=production npm run build"
```

Expand Down Expand Up @@ -96,7 +98,9 @@ NODE_ENV=production npm start
```bash
npm install cross-env
```

Then in your `package.json` scripts section:

```bash
"production": "cross-env NODE_ENV=production npm start"
```
Expand Down Expand Up @@ -1340,10 +1344,30 @@ If you plan to use **MongoDB** with your project, [refer to the create a Strapi
`Path: ./`
:::: tabs
::: tab yarn
Use **yarn** to install the Strapi project (**recommended**). [Install yarn with these docs](https://yarnpkg.com/lang/en/docs/install/)
```bash
strapi new my-project --quickstart
yarn create strapi-app my-project --quickstart
```
:::
::: tab npx
Use **npm/npx** to install the Strapi project
```bash
npx create-strapi-app my-project --quickstart
```
:::
::::
::: tip
When you use `--quickstart` to create a Strapi project locally, a **SQLite database** is used which is not compatible with Heroku. Therefore, another database option [must be chosen](#_6-heroku-database-set-up).
:::
Expand Down
6 changes: 3 additions & 3 deletions docs/3.0.0-beta.x/guides/slug.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ You will also need another `string` field that contains the slugified value of y

Let's configure the layout of the **edit page** to make it more user friendly for the content editor.

- Click on the **Content Manager** link in the left menu.
- Then on the `Article` Content Type.
- And finally on the **Edit View** tab.
- Click on the **Article** link in the left menu.
- Then on the `+ Add New Article` button.
- And finally on the `Configure the view` button.

Here we will be able to setup the `slug` field.

Expand Down
17 changes: 17 additions & 0 deletions docs/3.0.0-beta.x/plugins/graphql.md
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,23 @@ query {
}
```

### Fetch dynamic zone data

Dynamic zones are union types in graphql so you need to use fragments to query the fields.

```
query {
restaurants {
dz {
__typename
... on ComponentDefaultClosingperiod {
label
}
}
}
}
```

### Create a new entry

- `input`: Object
Expand Down
8 changes: 5 additions & 3 deletions docs/3.0.0-beta.x/plugins/users-permissions.md
Original file line number Diff line number Diff line change
Expand Up @@ -261,11 +261,11 @@ The `user` object is available to successfully authenticated requests.

```js
create: async ctx => {
const { _id } = ctx.state.user;
const { id } = ctx.state.user;

const depositObj = {
...ctx.request.body,
depositor: _id,
depositor: id,
};

const data = await strapi.services.deposit.add(depositObj);
Expand Down Expand Up @@ -437,7 +437,9 @@ You can update these template in the **Email Templates** tab in the admin panel.
- `URL` is the Strapi backend URL that confirm the code (by default `/auth/email-confirmation`).

## Security configuration
JWT tokens can be verified and trusted because the information is digitally signed. To sign a token a *secret* is required. By default Strapi generates one that is stored in `./your-app/extensions/users-permissions/config/jwt.json`. This is useful during development but for security reasons it is **recommended** to set a custom token via an environment variable `JWT_SECRET` when deploying to production. It is also possible to modify `jwt.json` file to accept `JWT_TOKEN` automatically by doing following ([docs](https://strapi.io/documentation/3.0.0-beta.x/concepts/configurations.html#dynamic-configurations)).

JWT tokens can be verified and trusted because the information is digitally signed. To sign a token a _secret_ is required. By default Strapi generates one that is stored in `./your-app/extensions/users-permissions/config/jwt.json`. This is useful during development but for security reasons it is **recommended** to set a custom token via an environment variable `JWT_SECRET` when deploying to production. It is also possible to modify `jwt.json` file to accept `JWT_TOKEN` automatically by doing following ([docs](https://strapi.io/documentation/3.0.0-beta.x/concepts/configurations.html#dynamic-configurations)).

```
"jwtSecret": "${process.env.JWT_SECRET}"
```
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
"enzyme-adapter-react-16": "^1.12.1",
"eslint": "^6.3.0",
"eslint-config-prettier": "^6.2.0",
"eslint-plugin-import": "^2.19.1",
"eslint-plugin-react": "^7.14.0",
"eslint-plugin-react-hooks": "^2.0.0",
"eslint-plugin-redux-saga": "^1.1.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/create-strapi-app/LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2015-2019 Strapi Solutions.
Copyright (c) 2015-2020 Strapi Solutions.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
2 changes: 1 addition & 1 deletion packages/strapi-admin/LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2015-2019 Strapi Solutions.
Copyright (c) 2015-2020 Strapi Solutions.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,8 @@

import React from 'react';
import { FormattedMessage } from 'react-intl';

import { Content, Wrapper } from './components';
import Icon from '../../assets/icons/icon_success.svg';
import { Content, Wrapper } from './components';

function DownloadInfo() {
return (
Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
import React from 'react';
import { shallow } from 'enzyme';

import { OverlayBlocker } from 'strapi-helper-plugin';
import {
disableGlobalOverlayBlocker,
enableGlobalOverlayBlocker,
updatePlugin,
} from '../../App/actions';

import { OverlayBlocker } from 'strapi-helper-plugin';

import { Admin, mapDispatchToProps } from '../index';
import { setAppError } from '../actions';

Expand Down
3 changes: 1 addition & 2 deletions packages/strapi-admin/admin/src/containers/App/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import { connect } from 'react-redux';
import { bindActionCreators, compose } from 'redux';
import { LoadingIndicatorPage, request } from 'strapi-helper-plugin';

import GlobalStyle from '../../components/GlobalStyle';
import Admin from '../Admin';
import AuthPage from '../AuthPage';
import NotFoundPage from '../NotFoundPage';
Expand All @@ -28,8 +29,6 @@ import Theme from '../Theme';

import { Content, Wrapper } from './components';

import GlobalStyle from '../../components/GlobalStyle';

import { getDataSucceeded } from './actions';

function App(props) {
Expand Down
13 changes: 9 additions & 4 deletions packages/strapi-admin/admin/src/translations/cs.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"app.components.BlockLink.code": "Příklady kódu",
"app.components.BlockLink.code.content": "Naučte se na příkladech vytvořených komunitou.",
"app.components.BlockLink.documentation": "Přečíst dokumentaci",
"app.components.BlockLink.documentation.content": "Objevte koncepty, referenční průvodce a tutoriály.",
"app.components.BlockLink.documentation.content": "Objevte koncepty, referenční průvodce a návody.",
"app.components.Button.cancel": "Zrušit",
"app.components.Button.save": "Uložit",
"app.components.ComingSoonPage.comingSoon": "Již brzy",
Expand All @@ -34,7 +34,7 @@
"app.components.HomePage.create": "Vytvořte svůj první Typ obsahu",
"app.components.HomePage.createBlock.content.first": "Tento ",
"app.components.HomePage.createBlock.content.second": " zásuvný modul vám pomůže definovat datovou strukturu vašich modelů. Pokud jste zde nový, velmi doporučujeme postupovat dle našeho ",
"app.components.HomePage.createBlock.content.tutorial": " tutoriálu.",
"app.components.HomePage.createBlock.content.tutorial": " návodu.",
"app.components.HomePage.cta": "POTVRDIT",
"app.components.HomePage.newsLetter": "Přihlaste se k odběru newsletteru a zůstaňte v kontaktu s projektem Strapi",
"app.components.HomePage.support": "PODPOŘTE NÁS",
Expand Down Expand Up @@ -105,14 +105,17 @@
"app.components.listPlugins.title.plural": "{number} zásuvných modulů je instalováno",
"app.components.listPlugins.title.singular": "{number} zásuvný modul je nainstalován",
"app.components.listPluginsPage.deletePlugin.error": "Došlo k chybě při odinstalaci zásuvného modulu",

"app.links.configure-view": "Upravit vzhled",

"app.utils.SelectOption.defaultMessage": " ",
"app.utils.defaultMessage": " ",
"app.utils.placeholder.defaultMessage": " ",
"components.AutoReloadBlocker.description": "Spusťte Strapi jedním z následujících příkazů:",
"components.AutoReloadBlocker.header": "Pro tento zásuvný modul musí být zapnuta funkce znovu načítání.",
"components.ErrorBoundary.title": "Něco se pokazilo...",
"components.Input.error.attribute.key.taken": "Tato hodnota již existuje",
"components.Input.error.attribute.sameKeyAndName": "Nemůže se rovnat",
"components.Input.error.attribute.sameKeyAndName": "Hodnoty nesmí být stejné",
"components.Input.error.attribute.taken": "Název tohoto pole již existuje",
"components.Input.error.contentTypeName.taken": "Tento název již existuje",
"components.Input.error.custom-error": "{errorMessage} ",
Expand All @@ -123,9 +126,11 @@
"components.Input.error.validation.min": "Hodnota je příliš nízká.",
"components.Input.error.validation.minLength": "Hodnota je příliš krátká.",
"components.Input.error.validation.minSupMax": "Nemůže být nadřazený",
"components.Input.error.validation.regex": "Hodnota neodpovídá regexu.",
"components.Input.error.validation.regex": "Hodnota neodpovídá požadovanému vzoru.",
"components.Input.error.validation.required": "Tato hodnota je povinná.",
"components.Input.error.validation.unique": "Tato hodnota již byla použita.",
"components.InputSelect.option.placeholder": "Vyberte zde",
"component.Input.error.validation.integer": "Tato hodnota musí být celé číslo",
"components.ListRow.empty": "Žádná data k zobrazení.",
"components.OverlayBlocker.description": "Používáte funkcionalitu, která potřebuje restartovat server. Počkejte, až se server opět spustí.",
"components.OverlayBlocker.description.serverError": "Server by měl být restartován, zkontrolujte prosím protokoly v terminálu.",
Expand Down
2 changes: 1 addition & 1 deletion packages/strapi-admin/admin/src/translations/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@
"app.components.PluginCard.compatible": "Compatible with your app",
"app.components.PluginCard.compatibleCommunity": "Compatible with the community",
"app.components.PluginCard.more-details": "More details",
"app.components.PluginCard.PopUpWarning.install.impossible.autoReload.needed": "The autoReload feature needs to be unabled. Please start you app with `yarn develop`.",
"app.components.PluginCard.PopUpWarning.install.impossible.autoReload.needed": "The autoReload feature needs to be enabled. Please start your app with `yarn develop`.",
"app.components.PluginCard.PopUpWarning.install.impossible.environment": "For security reasons, a plugin can only be downloaded in a development environment.",
"app.components.PluginCard.PopUpWarning.install.impossible.confirm": "I understand!",
"app.components.PluginCard.PopUpWarning.install.impossible.title": "Downloading is impossible",
Expand Down
2 changes: 1 addition & 1 deletion packages/strapi-admin/controllers/Auth.js
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,7 @@ module.exports = {
email: 'no-reply@strapi.io',
},
response_email: '',
object: '­Reset password',
object: 'Reset password',
message: `<p>We heard that you lost your password. Sorry about that!</p>
<p>But don’t worry! You can use the following link to reset your password:</p>
Expand Down
2 changes: 1 addition & 1 deletion packages/strapi-connector-bookshelf/LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2015-2019 Strapi Solutions.
Copyright (c) 2015-2020 Strapi Solutions.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
2 changes: 1 addition & 1 deletion packages/strapi-connector-mongoose/LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2015-2019 Strapi Solutions.
Copyright (c) 2015-2020 Strapi Solutions.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
2 changes: 1 addition & 1 deletion packages/strapi-database/LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2015-2019 Strapi Solutions.
Copyright (c) 2015-2020 Strapi Solutions.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
2 changes: 1 addition & 1 deletion packages/strapi-generate-api/LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2015-2019 Strapi Solutions.
Copyright (c) 2015-2020 Strapi Solutions.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
2 changes: 1 addition & 1 deletion packages/strapi-generate-controller/LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2015-2019 Strapi Solutions.
Copyright (c) 2015-2020 Strapi Solutions.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
2 changes: 1 addition & 1 deletion packages/strapi-generate-model/LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2015-2019 Strapi Solutions.
Copyright (c) 2015-2020 Strapi Solutions.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
2 changes: 1 addition & 1 deletion packages/strapi-generate-new/LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2015-2019 Strapi Solutions.
Copyright (c) 2015-2020 Strapi Solutions.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
3 changes: 2 additions & 1 deletion packages/strapi-generate-new/lib/create-project.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ const fse = require('fs-extra');
const chalk = require('chalk');
const execa = require('execa');
const ora = require('ora');
const _ = require('lodash');

const stopProcess = require('./utils/stop-process');
const { trackUsage, captureStderr } = require('./utils/usage');
Expand Down Expand Up @@ -42,7 +43,7 @@ module.exports = async function createProject(
strapiDependencies: scope.strapiDependencies,
additionalsDependencies: dependencies,
strapiVersion: scope.strapiVersion,
projectName: scope.name,
projectName: _.kebabCase(scope.name),
uuid: scope.uuid,
}),
{
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"welcome": "Vítejte"
}
2 changes: 1 addition & 1 deletion packages/strapi-generate-plugin/LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2015-2019 Strapi Solutions.
Copyright (c) 2015-2020 Strapi Solutions.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
2 changes: 1 addition & 1 deletion packages/strapi-generate-policy/LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2015-2019 Strapi Solutions.
Copyright (c) 2015-2020 Strapi Solutions.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
2 changes: 1 addition & 1 deletion packages/strapi-generate-service/LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2015-2019 Strapi Solutions.
Copyright (c) 2015-2020 Strapi Solutions.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down
2 changes: 1 addition & 1 deletion packages/strapi-helper-plugin/LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright (c) 2015-2019 Strapi Solutions.
Copyright (c) 2015-2020 Strapi Solutions.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

Expand Down

0 comments on commit bfe37c7

Please sign in to comment.