@punch-in/strapi-admin 1.0.1 → 1.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -5,31 +5,20 @@
|
|
|
5
5
|
|
|
6
6
|
import React, { memo } from 'react';
|
|
7
7
|
import PropTypes from 'prop-types';
|
|
8
|
-
|
|
9
|
-
import Gh from '../../assets/images/social_gh.png';
|
|
10
|
-
import Discord from '../../assets/images/social_discord.png';
|
|
11
|
-
import Twitter from '../../assets/images/social_twitter.png';
|
|
12
|
-
import Reddit from '../../assets/images/social_reddit.png';
|
|
13
|
-
import Strapi from '../../assets/images/social_strapi.png';
|
|
8
|
+
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
|
|
14
9
|
|
|
15
10
|
import { SocialLinkWrapper } from './components';
|
|
16
11
|
|
|
17
12
|
function getSrc(name) {
|
|
18
13
|
switch (name) {
|
|
19
|
-
case '
|
|
20
|
-
return
|
|
21
|
-
case '
|
|
22
|
-
return
|
|
23
|
-
case 'Discord':
|
|
24
|
-
return Discord;
|
|
25
|
-
case 'Twitter':
|
|
26
|
-
return Twitter;
|
|
27
|
-
case 'Blog':
|
|
28
|
-
case 'Forum':
|
|
14
|
+
case 'Facebook':
|
|
15
|
+
return (<FontAwesomeIcon icon="fa-brands fa-square-facebook" size="lg" />);
|
|
16
|
+
case 'LinkedIn':
|
|
17
|
+
return (<FontAwesomeIcon icon="fa-brands fa-linkedin" size="lg" />);
|
|
29
18
|
case 'Careers':
|
|
30
|
-
return
|
|
19
|
+
return (<FontAwesomeIcon icon="fa-brands fa-linkedin" size="lg" color="#4199e1" />);
|
|
31
20
|
default:
|
|
32
|
-
return
|
|
21
|
+
return (<FontAwesomeIcon icon="fa-brands fa-linkedin" size="lg" />) />;
|
|
33
22
|
}
|
|
34
23
|
}
|
|
35
24
|
|
|
@@ -19,45 +19,29 @@ import SocialLink from './SocialLink';
|
|
|
19
19
|
const FIRST_BLOCK_LINKS = [
|
|
20
20
|
{
|
|
21
21
|
link:
|
|
22
|
-
'https://
|
|
22
|
+
'https://www.punch-in.co.uk/#docs',
|
|
23
23
|
contentId: 'app.components.BlockLink.documentation.content',
|
|
24
24
|
titleId: 'app.components.BlockLink.documentation',
|
|
25
25
|
},
|
|
26
26
|
{
|
|
27
|
-
link: 'https://
|
|
28
|
-
contentId: 'app.components.BlockLink.
|
|
29
|
-
titleId: 'app.components.BlockLink.
|
|
27
|
+
link: 'https://www.punch-in.co.uk/faq',
|
|
28
|
+
contentId: 'app.components.BlockLink.documentation.faq',
|
|
29
|
+
titleId: 'app.components.BlockLink.faq',
|
|
30
30
|
},
|
|
31
31
|
];
|
|
32
32
|
|
|
33
33
|
const SOCIAL_LINKS = [
|
|
34
34
|
{
|
|
35
|
-
name: '
|
|
36
|
-
link: 'https://
|
|
35
|
+
name: 'LinkedIn',
|
|
36
|
+
link: 'https://www.linkedin.com/company/punch-in-uk/',
|
|
37
37
|
},
|
|
38
38
|
{
|
|
39
|
-
name: '
|
|
40
|
-
link: 'https://
|
|
41
|
-
},
|
|
42
|
-
{
|
|
43
|
-
name: 'Reddit',
|
|
44
|
-
link: 'https://www.reddit.com/r/Strapi/',
|
|
45
|
-
},
|
|
46
|
-
{
|
|
47
|
-
name: 'Twitter',
|
|
48
|
-
link: 'https://twitter.com/strapijs',
|
|
49
|
-
},
|
|
50
|
-
{
|
|
51
|
-
name: 'Blog',
|
|
52
|
-
link: 'https://strapi.io/blog',
|
|
53
|
-
},
|
|
54
|
-
{
|
|
55
|
-
name: 'Forum',
|
|
56
|
-
link: 'https://forum.strapi.io',
|
|
39
|
+
name: 'Facebook',
|
|
40
|
+
link: 'https://www.facebook.com/punch.in.uk',
|
|
57
41
|
},
|
|
58
42
|
{
|
|
59
43
|
name: 'Careers',
|
|
60
|
-
link: 'https://
|
|
44
|
+
link: 'https://www.punch-in.co.uk/careers',
|
|
61
45
|
},
|
|
62
46
|
];
|
|
63
47
|
|
|
@@ -152,30 +136,6 @@ const HomePage = ({ history: { push } }) => {
|
|
|
152
136
|
}}
|
|
153
137
|
</FormattedMessage>
|
|
154
138
|
)}
|
|
155
|
-
{hasAlreadyCreatedContentTypes && (
|
|
156
|
-
<div style={{ marginTop: isLoading ? 60 : 50 }}>
|
|
157
|
-
{posts.map((post, index) => (
|
|
158
|
-
<BlogPost
|
|
159
|
-
{...post}
|
|
160
|
-
key={post.link}
|
|
161
|
-
isFirst={index === 0}
|
|
162
|
-
isLoading={isLoading}
|
|
163
|
-
error={error}
|
|
164
|
-
/>
|
|
165
|
-
))}
|
|
166
|
-
</div>
|
|
167
|
-
)}
|
|
168
|
-
<FormattedMessage id={linkProps.id}>
|
|
169
|
-
{msg => (
|
|
170
|
-
<ALink
|
|
171
|
-
rel="noopener noreferrer"
|
|
172
|
-
{...linkProps}
|
|
173
|
-
style={{ verticalAlign: ' bottom', marginBottom: 5 }}
|
|
174
|
-
>
|
|
175
|
-
{msg}
|
|
176
|
-
</ALink>
|
|
177
|
-
)}
|
|
178
|
-
</FormattedMessage>
|
|
179
139
|
<Separator style={{ marginTop: 37, marginBottom: 36 }} />
|
|
180
140
|
<div style={{ display: 'flex', justifyContent: 'space-between' }}>
|
|
181
141
|
{FIRST_BLOCK_LINKS.map((data, index) => {
|
package/index.js
CHANGED
|
@@ -8,7 +8,7 @@ const WebpackDevServer = require('webpack-dev-server');
|
|
|
8
8
|
const chalk = require('chalk');
|
|
9
9
|
const chokidar = require('chokidar');
|
|
10
10
|
// eslint-disable-next-line node/no-extraneous-require
|
|
11
|
-
const hasEE = require('strapi/lib/utils/ee');
|
|
11
|
+
const hasEE = require('@punch-in/strapi/lib/utils/ee');
|
|
12
12
|
const getWebpackConfig = require('./webpack.config.js');
|
|
13
13
|
|
|
14
14
|
const getPkgPath = name => path.dirname(require.resolve(`${name}/package.json`));
|
|
@@ -154,7 +154,7 @@ async function copyPlugin(name, dest) {
|
|
|
154
154
|
}
|
|
155
155
|
|
|
156
156
|
async function copyAdmin(dest) {
|
|
157
|
-
const adminPath = getPkgPath('strapi-admin');
|
|
157
|
+
const adminPath = getPkgPath('@punch-in/strapi-admin');
|
|
158
158
|
|
|
159
159
|
// TODO copy ee folders for plugins
|
|
160
160
|
await fs.copy(path.resolve(adminPath, 'ee', 'admin'), path.resolve(dest, 'ee', 'admin'));
|
|
@@ -181,7 +181,7 @@ async function createCacheDir(dir) {
|
|
|
181
181
|
|
|
182
182
|
const pluginsToCopy = Object.keys(pkgJSON.dependencies).filter(
|
|
183
183
|
dep =>
|
|
184
|
-
dep.
|
|
184
|
+
dep.includes('strapi-plugin') &&
|
|
185
185
|
fs.existsSync(path.resolve(getPkgPath(dep), 'admin', 'src', 'index.js'))
|
|
186
186
|
);
|
|
187
187
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@punch-in/strapi-admin",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.4",
|
|
4
4
|
"description": "Strapi Admin",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -37,6 +37,7 @@
|
|
|
37
37
|
"@fortawesome/free-brands-svg-icons": "^5.15.3",
|
|
38
38
|
"@fortawesome/free-solid-svg-icons": "^5.15.3",
|
|
39
39
|
"@fortawesome/react-fontawesome": "^0.1.14",
|
|
40
|
+
"@punch-in/strapi": "file:/webapps/punch-in-repo/strapi",
|
|
40
41
|
"autoprefixer": "^9.8.6",
|
|
41
42
|
"axios": "^0.21.1",
|
|
42
43
|
"babel-loader": "^8.1.0",
|