generator-folklore 3.0.15 → 3.0.17
Sign up to get free protection for your applications and to get access to all the features.
- package/lib/generators/app/index.js +3 -18
- package/lib/generators/babel/index.js +0 -12
- package/lib/generators/browserslist/index.js +0 -7
- package/lib/generators/build/index.js +0 -17
- package/lib/generators/cli/index.js +0 -18
- package/lib/generators/docs/index.js +3 -32
- package/lib/generators/editorconfig/index.js +0 -6
- package/lib/generators/eslint/index.js +0 -11
- package/lib/generators/html-project/index.js +0 -30
- package/lib/generators/intl/index.js +0 -13
- package/lib/generators/laravel/index.js +3 -75
- package/lib/generators/laravel-auth/index.js +0 -25
- package/lib/generators/laravel-mediatheque/index.js +0 -28
- package/lib/generators/laravel-package/index.js +0 -33
- package/lib/generators/laravel-panneau/index.js +0 -49
- package/lib/generators/laravel-project/index.js +9 -76
- package/lib/generators/laravel-project/templates/laravel/config/app.php +1 -0
- package/lib/generators/laravel-project/templates/laravel/lang/en/auth.php +18 -0
- package/lib/generators/laravel-project/templates/laravel/lang/en/pagination.php +17 -0
- package/lib/generators/laravel-project/templates/laravel/lang/en/passwords.php +20 -0
- package/lib/generators/laravel-project/templates/laravel/lang/en/validation.php +167 -0
- package/lib/generators/lerna-package/index.js +0 -36
- package/lib/generators/lerna-repository/index.js +0 -34
- package/lib/generators/node-project/index.js +0 -28
- package/lib/generators/npm-package/index.js +0 -36
- package/lib/generators/prettier/index.js +0 -11
- package/lib/generators/react-app/index.js +3 -28
- package/lib/generators/react-package/index.js +0 -33
- package/lib/generators/rollup/index.js +0 -13
- package/lib/generators/sass-lint/index.js +0 -9
- package/lib/generators/scss/index.js +0 -16
- package/lib/generators/server/index.js +0 -15
- package/lib/generators/storybook/index.js +0 -16
- package/lib/generators/stylelint/index.js +0 -11
- package/lib/generators/stylelint/templates/stylelintrc +2 -1
- package/lib/generators/test/index.js +0 -16
- package/lib/lib/generator.js +3 -22
- package/lib/lib/mysql.js +0 -10
- package/lib/lib/utils.js +0 -4
- package/package.json +2 -2
@@ -1,36 +1,25 @@
|
|
1
1
|
"use strict";
|
2
2
|
|
3
3
|
var _chalk = _interopRequireDefault(require("chalk"));
|
4
|
-
|
5
4
|
var _glob = _interopRequireDefault(require("glob"));
|
6
|
-
|
7
5
|
var _lodash = _interopRequireDefault(require("lodash"));
|
8
|
-
|
9
6
|
var _passwordGenerator = _interopRequireDefault(require("password-generator"));
|
10
|
-
|
11
7
|
var _path = _interopRequireDefault(require("path"));
|
12
|
-
|
13
8
|
var _yeomanRemote = _interopRequireDefault(require("yeoman-remote"));
|
14
|
-
|
15
9
|
var _generator = _interopRequireDefault(require("../../lib/generator"));
|
16
|
-
|
17
10
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
18
|
-
|
19
11
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
20
|
-
|
21
12
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
22
|
-
|
23
|
-
function
|
24
|
-
|
13
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
14
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
15
|
+
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
25
16
|
module.exports = class LaravelProjectGenerator extends _generator.default {
|
26
17
|
static safeDbString(str) {
|
27
18
|
return str.replace(/[-s.]+/gi, '_').replace(/[^a-z0-9]+/gi, '');
|
28
19
|
}
|
29
|
-
|
30
20
|
static getPassword() {
|
31
21
|
return (0, _passwordGenerator.default)(20, false);
|
32
22
|
}
|
33
|
-
|
34
23
|
constructor(...args) {
|
35
24
|
super(...args);
|
36
25
|
this.argument('project-name', {
|
@@ -120,26 +109,21 @@ module.exports = class LaravelProjectGenerator extends _generator.default {
|
|
120
109
|
defaults: false
|
121
110
|
});
|
122
111
|
}
|
123
|
-
|
124
112
|
get prompting() {
|
125
113
|
return {
|
126
114
|
welcome() {
|
127
115
|
if (this.options.quiet) {
|
128
116
|
return;
|
129
117
|
}
|
130
|
-
|
131
118
|
console.log(_chalk.default.yellow('\n----------------------'));
|
132
119
|
console.log('Laravel Generator');
|
133
120
|
console.log(_chalk.default.yellow('----------------------\n'));
|
134
121
|
},
|
135
|
-
|
136
122
|
prompts() {
|
137
123
|
const prompts = [];
|
138
|
-
|
139
124
|
if (!this.options['project-name']) {
|
140
125
|
prompts.push(_generator.default.prompts.project_name);
|
141
126
|
}
|
142
|
-
|
143
127
|
if (!this.options['project-host']) {
|
144
128
|
prompts.push({
|
145
129
|
type: 'input',
|
@@ -151,7 +135,6 @@ module.exports = class LaravelProjectGenerator extends _generator.default {
|
|
151
135
|
}
|
152
136
|
});
|
153
137
|
}
|
154
|
-
|
155
138
|
if (!this.options['db-name']) {
|
156
139
|
prompts.push({
|
157
140
|
type: 'input',
|
@@ -163,7 +146,6 @@ module.exports = class LaravelProjectGenerator extends _generator.default {
|
|
163
146
|
}
|
164
147
|
});
|
165
148
|
}
|
166
|
-
|
167
149
|
const featuresChoices = [!this.options.mediatheque && {
|
168
150
|
name: 'Mediatheque',
|
169
151
|
value: 'mediatheque',
|
@@ -177,7 +159,6 @@ module.exports = class LaravelProjectGenerator extends _generator.default {
|
|
177
159
|
value: 'auth',
|
178
160
|
checked: true
|
179
161
|
}].filter(Boolean);
|
180
|
-
|
181
162
|
if (featuresChoices.length) {
|
182
163
|
prompts.push({
|
183
164
|
type: 'checkbox',
|
@@ -187,56 +168,40 @@ module.exports = class LaravelProjectGenerator extends _generator.default {
|
|
187
168
|
default: featuresChoices.filter(it => it.checked || false).map(it => it.name)
|
188
169
|
});
|
189
170
|
}
|
190
|
-
|
191
171
|
if (!prompts.length) {
|
192
172
|
return null;
|
193
173
|
}
|
194
|
-
|
195
174
|
return this.prompt(prompts).then(answers => {
|
196
175
|
if (answers['project-name']) {
|
197
176
|
this.options['project-name'] = answers['project-name'];
|
198
177
|
}
|
199
|
-
|
200
178
|
if (answers['project-host']) {
|
201
179
|
this.options['project-host'] = answers['project-host'];
|
202
180
|
}
|
203
|
-
|
204
181
|
if (answers['db-name']) {
|
205
182
|
this.options['db-name'] = answers['db-name'];
|
206
183
|
}
|
207
|
-
|
208
184
|
const features = answers.features || [];
|
209
|
-
|
210
185
|
if (features.indexOf('panneau') !== -1) {
|
211
186
|
this.options.panneau = true;
|
212
187
|
}
|
213
|
-
|
214
188
|
if (features.indexOf('auth') !== -1) {
|
215
189
|
this.options.auth = true;
|
216
190
|
}
|
217
|
-
|
218
191
|
if (features.indexOf('mediatheque') !== -1) {
|
219
192
|
this.options.mediatheque = true;
|
220
193
|
}
|
221
194
|
});
|
222
195
|
}
|
223
|
-
|
224
196
|
};
|
225
197
|
}
|
226
|
-
|
227
198
|
configuring() {
|
228
199
|
const assetsPath = _lodash.default.get(this.options, 'assets-path', '').replace(/\/$/, '');
|
229
|
-
|
230
200
|
const publicPath = _lodash.default.get(this.options, 'public-path');
|
231
|
-
|
232
201
|
const jsPath = _lodash.default.get(this.options, 'js-path');
|
233
|
-
|
234
202
|
const jsSrcPath = _path.default.join(assetsPath, jsPath);
|
235
|
-
|
236
203
|
const stylesPath = _lodash.default.get(this.options, 'styles-path');
|
237
|
-
|
238
204
|
const stylesSrcPath = _path.default.join(assetsPath, stylesPath);
|
239
|
-
|
240
205
|
this.composeWith('folklore:prettier', {
|
241
206
|
'skip-install': true,
|
242
207
|
quiet: true
|
@@ -285,7 +250,6 @@ module.exports = class LaravelProjectGenerator extends _generator.default {
|
|
285
250
|
quiet: true,
|
286
251
|
'skip-install': true
|
287
252
|
});
|
288
|
-
|
289
253
|
if (this.options.mediatheque) {
|
290
254
|
this.composeWith('folklore:laravel-mediatheque', {
|
291
255
|
'project-name': this.options['project-name'],
|
@@ -293,14 +257,15 @@ module.exports = class LaravelProjectGenerator extends _generator.default {
|
|
293
257
|
quiet: true
|
294
258
|
});
|
295
259
|
}
|
296
|
-
|
297
260
|
if (this.options.panneau) {
|
298
261
|
this.composeWith('folklore:laravel-panneau', {
|
299
262
|
'project-name': this.options['project-name'],
|
300
263
|
'skip-install': true,
|
301
264
|
quiet: true
|
302
265
|
});
|
303
|
-
}
|
266
|
+
}
|
267
|
+
|
268
|
+
// if (this.options.auth) {
|
304
269
|
// this.composeWith('folklore:laravel-auth', {
|
305
270
|
// 'project-name': this.options['project-name'],
|
306
271
|
// 'js-path': jsSrcPath,
|
@@ -310,7 +275,6 @@ module.exports = class LaravelProjectGenerator extends _generator.default {
|
|
310
275
|
// quiet: true,
|
311
276
|
// });
|
312
277
|
// }
|
313
|
-
|
314
278
|
}
|
315
279
|
|
316
280
|
get writing() {
|
@@ -323,36 +287,30 @@ module.exports = class LaravelProjectGenerator extends _generator.default {
|
|
323
287
|
} = this.options;
|
324
288
|
const versionBranch = laravelVersion !== 'latest' && laravelVersion !== null ? `${laravelVersion.indexOf('.') !== -1 ? laravelVersion : `${laravelVersion}.x`}` : null;
|
325
289
|
const branch = laravelBranch || versionBranch;
|
326
|
-
|
327
290
|
const remoteCallback = (err, cachePath) => {
|
328
291
|
const destinationPath = this.destinationPath();
|
329
|
-
|
330
292
|
const files = _glob.default.sync('**', {
|
331
293
|
dot: true,
|
332
294
|
nodir: true,
|
333
295
|
cwd: cachePath
|
334
296
|
});
|
335
|
-
|
336
297
|
let source;
|
337
298
|
let destination;
|
338
299
|
files.forEach(file => {
|
339
300
|
source = _path.default.join(cachePath, file);
|
340
301
|
destination = _path.default.join(destinationPath, file);
|
341
|
-
|
342
302
|
if (!this.fs.exists(destination)) {
|
343
303
|
this.fs.copy(source, destination);
|
344
304
|
}
|
345
305
|
});
|
346
306
|
done();
|
347
307
|
};
|
348
|
-
|
349
308
|
if (branch !== null) {
|
350
309
|
(0, _yeomanRemote.default)('laravel', 'laravel', branch, remoteCallback);
|
351
310
|
} else {
|
352
311
|
(0, _yeomanRemote.default)('laravel', 'laravel', remoteCallback);
|
353
312
|
}
|
354
313
|
},
|
355
|
-
|
356
314
|
removeFiles() {
|
357
315
|
const files = ['package.json', 'config/app.php', 'config/auth.php', 'routes/web.php', 'vite.config.js', 'resources/css', 'resources/js', 'resources/views/welcome.blade.php', 'app/Http/Controllers/HomeController.php', 'app/Http/Middleware/TrustProxies.php', 'app/Models/User.php'];
|
358
316
|
files.forEach(file => {
|
@@ -360,7 +318,6 @@ module.exports = class LaravelProjectGenerator extends _generator.default {
|
|
360
318
|
this.fs.delete(filePath);
|
361
319
|
});
|
362
320
|
},
|
363
|
-
|
364
321
|
composerJSON() {
|
365
322
|
this.composerJson.merge({
|
366
323
|
require: {
|
@@ -380,7 +337,6 @@ module.exports = class LaravelProjectGenerator extends _generator.default {
|
|
380
337
|
'prefer-stable': true
|
381
338
|
});
|
382
339
|
},
|
383
|
-
|
384
340
|
packageJSON() {
|
385
341
|
this.packageJson.merge({
|
386
342
|
scripts: {
|
@@ -393,23 +349,19 @@ module.exports = class LaravelProjectGenerator extends _generator.default {
|
|
393
349
|
}
|
394
350
|
});
|
395
351
|
},
|
396
|
-
|
397
352
|
env() {
|
398
353
|
const url = _lodash.default.template(_lodash.default.get(this.options, 'url'))({
|
399
354
|
project_host: this.options['project-host'],
|
400
355
|
project_name: this.options['project-name']
|
401
356
|
}).replace(/^(http)?(s)?(:\/\/)?/, 'http$2://');
|
402
|
-
|
403
357
|
const urlLocal = _lodash.default.template(_lodash.default.get(this.options, 'local-url'))({
|
404
358
|
project_host: this.options['project-host'],
|
405
359
|
project_name: this.options['project-name']
|
406
360
|
}).replace(/^(http)?(s)?(:\/\/)?/, 'http$2://');
|
407
|
-
|
408
361
|
const urlProxy = _lodash.default.template(_lodash.default.get(this.options, 'proxy-url', _lodash.default.get(this.options, 'local-url')))({
|
409
362
|
project_host: this.options['project-host'],
|
410
363
|
project_name: this.options['project-name']
|
411
364
|
}).replace(/^(http)?(s)?(:\/\/)?/, 'http$2://');
|
412
|
-
|
413
365
|
const templateData = {
|
414
366
|
project_name: this.options['project-name'],
|
415
367
|
db_host: this.options['db-host'],
|
@@ -419,18 +371,18 @@ module.exports = class LaravelProjectGenerator extends _generator.default {
|
|
419
371
|
url: urlLocal,
|
420
372
|
proxy_url: urlProxy
|
421
373
|
};
|
422
|
-
|
423
374
|
const prodTemplateData = _objectSpread(_objectSpread({}, templateData), {}, {
|
424
375
|
url,
|
425
376
|
db_username: this.options['db-name']
|
426
377
|
});
|
427
|
-
|
428
378
|
const src = this.templatePath('env');
|
429
379
|
const dest = this.destinationPath('.env');
|
430
380
|
this.fs.copyTpl(src, dest, templateData);
|
431
381
|
const srcExample = this.templatePath('env');
|
432
382
|
const destExample = this.destinationPath('.env.example');
|
433
|
-
this.fs.copyTpl(srcExample, destExample, templateData);
|
383
|
+
this.fs.copyTpl(srcExample, destExample, templateData);
|
384
|
+
|
385
|
+
// const srcProd = this.templatePath('env.prod');
|
434
386
|
// const destProd = this.destinationPath('.env.prod');
|
435
387
|
// this.fs.copyTpl(srcProd, destProd, prodTemplateData);
|
436
388
|
},
|
@@ -438,18 +390,14 @@ module.exports = class LaravelProjectGenerator extends _generator.default {
|
|
438
390
|
files() {
|
439
391
|
const templatePath = this.templatePath('laravel');
|
440
392
|
const destinationPath = this.destinationPath();
|
441
|
-
|
442
393
|
const files = _glob.default.sync('**', {
|
443
394
|
dot: true,
|
444
395
|
nodir: true,
|
445
396
|
cwd: templatePath
|
446
397
|
});
|
447
|
-
|
448
398
|
files.forEach(file => {
|
449
399
|
const source = _path.default.join(templatePath, file);
|
450
|
-
|
451
400
|
const destination = _path.default.join(destinationPath, file);
|
452
|
-
|
453
401
|
if (file.match(/\.php$/i)) {
|
454
402
|
this.fs.copyTpl(source, destination, {
|
455
403
|
options: this.options
|
@@ -459,63 +407,48 @@ module.exports = class LaravelProjectGenerator extends _generator.default {
|
|
459
407
|
}
|
460
408
|
});
|
461
409
|
}
|
462
|
-
|
463
410
|
};
|
464
411
|
}
|
465
|
-
|
466
412
|
get install() {
|
467
413
|
return {
|
468
414
|
async npm() {
|
469
415
|
if (this.options['skip-install']) {
|
470
416
|
return;
|
471
417
|
}
|
472
|
-
|
473
418
|
await this.spawnCommand('npm', ['install']);
|
474
419
|
},
|
475
|
-
|
476
420
|
async composer() {
|
477
421
|
if (this.options['skip-install']) {
|
478
422
|
return;
|
479
423
|
}
|
480
|
-
|
481
424
|
await this.spawnCommand('composer', ['install']);
|
482
425
|
},
|
483
|
-
|
484
426
|
async keyGenerate() {
|
485
427
|
if (this.options['skip-install']) {
|
486
428
|
return;
|
487
429
|
}
|
488
|
-
|
489
430
|
await this.spawnCommand('php', ['artisan', 'key:generate']);
|
490
431
|
},
|
491
|
-
|
492
432
|
async vendorPublish() {
|
493
433
|
if (this.options['skip-install']) {
|
494
434
|
return;
|
495
435
|
}
|
496
|
-
|
497
436
|
await this.spawnCommand('php', ['artisan', 'vendor:publish', '--provider=Folklore\\ServiceProvider']);
|
498
437
|
await this.spawnCommand('php', ['artisan', 'vendor:publish', '--provider=Folklore\\Locale\\LocaleServiceProvider']);
|
499
438
|
await this.spawnCommand('php', ['artisan', 'vendor:publish', '--provider=Folklore\\Image\\ServiceProvider']);
|
500
439
|
},
|
501
|
-
|
502
440
|
async telescope() {
|
503
441
|
if (this.options['skip-install']) {
|
504
442
|
return;
|
505
443
|
}
|
506
|
-
|
507
444
|
await this.spawnCommand('php', ['artisan', 'telescope:install']);
|
508
445
|
},
|
509
|
-
|
510
446
|
async valet() {
|
511
447
|
if (this.options['skip-install']) {
|
512
448
|
return;
|
513
449
|
}
|
514
|
-
|
515
450
|
await this.spawnCommand('valet', ['link', '--secure', this.options['project-host']]);
|
516
451
|
}
|
517
|
-
|
518
452
|
};
|
519
453
|
}
|
520
|
-
|
521
454
|
};
|
@@ -196,6 +196,7 @@ return [
|
|
196
196
|
App\Providers\EventServiceProvider::class,
|
197
197
|
App\Providers\RouteServiceProvider::class,
|
198
198
|
App\Providers\ViewServiceProvider::class,<% if (options.panneau) { %>
|
199
|
+
App\Providers\FortifyServiceProvider::class,
|
199
200
|
App\Panneau\PanneauServiceProvider::class,<% } %>
|
200
201
|
],
|
201
202
|
|
@@ -0,0 +1,18 @@
|
|
1
|
+
<?php
|
2
|
+
|
3
|
+
return [
|
4
|
+
/*
|
5
|
+
|--------------------------------------------------------------------------
|
6
|
+
| Authentication Language Lines
|
7
|
+
|--------------------------------------------------------------------------
|
8
|
+
|
|
9
|
+
| The following language lines are used during authentication for various
|
10
|
+
| messages that we need to display to the user. You are free to modify
|
11
|
+
| these language lines according to your application's requirements.
|
12
|
+
|
|
13
|
+
*/
|
14
|
+
|
15
|
+
'failed' => 'These credentials do not match our records.',
|
16
|
+
'password' => 'The provided password is incorrect.',
|
17
|
+
'throttle' => 'Too many login attempts. Please try again in :seconds seconds.',
|
18
|
+
];
|
@@ -0,0 +1,17 @@
|
|
1
|
+
<?php
|
2
|
+
|
3
|
+
return [
|
4
|
+
/*
|
5
|
+
|--------------------------------------------------------------------------
|
6
|
+
| Pagination Language Lines
|
7
|
+
|--------------------------------------------------------------------------
|
8
|
+
|
|
9
|
+
| The following language lines are used by the paginator library to build
|
10
|
+
| the simple pagination links. You are free to change them to anything
|
11
|
+
| you want to customize your views to better match your application.
|
12
|
+
|
|
13
|
+
*/
|
14
|
+
|
15
|
+
'previous' => '« Previous',
|
16
|
+
'next' => 'Next »',
|
17
|
+
];
|
@@ -0,0 +1,20 @@
|
|
1
|
+
<?php
|
2
|
+
|
3
|
+
return [
|
4
|
+
/*
|
5
|
+
|--------------------------------------------------------------------------
|
6
|
+
| Password Reset Language Lines
|
7
|
+
|--------------------------------------------------------------------------
|
8
|
+
|
|
9
|
+
| The following language lines are the default lines which match reasons
|
10
|
+
| that are given by the password broker for a password update attempt
|
11
|
+
| has failed, such as for an invalid token or invalid new password.
|
12
|
+
|
|
13
|
+
*/
|
14
|
+
|
15
|
+
'reset' => 'Your password has been reset!',
|
16
|
+
'sent' => 'We have emailed your password reset link!',
|
17
|
+
'throttled' => 'Please wait before retrying.',
|
18
|
+
'token' => 'This password reset token is invalid.',
|
19
|
+
'user' => "We can't find a user with that email address.",
|
20
|
+
];
|
@@ -0,0 +1,167 @@
|
|
1
|
+
<?php
|
2
|
+
|
3
|
+
return [
|
4
|
+
/*
|
5
|
+
|--------------------------------------------------------------------------
|
6
|
+
| Validation Language Lines
|
7
|
+
|--------------------------------------------------------------------------
|
8
|
+
|
|
9
|
+
| The following language lines contain the default error messages used by
|
10
|
+
| the validator class. Some of these rules have multiple versions such
|
11
|
+
| as the size rules. Feel free to tweak each of these messages here.
|
12
|
+
|
|
13
|
+
*/
|
14
|
+
|
15
|
+
'accepted' => 'The :attribute must be accepted.',
|
16
|
+
'accepted_if' => 'The :attribute must be accepted when :other is :value.',
|
17
|
+
'active_url' => 'The :attribute is not a valid URL.',
|
18
|
+
'after' => 'The :attribute must be a date after :date.',
|
19
|
+
'after_or_equal' => 'The :attribute must be a date after or equal to :date.',
|
20
|
+
'alpha' => 'The :attribute must only contain letters.',
|
21
|
+
'alpha_dash' => 'The :attribute must only contain letters, numbers, dashes and underscores.',
|
22
|
+
'alpha_num' => 'The :attribute must only contain letters and numbers.',
|
23
|
+
'array' => 'The :attribute must be an array.',
|
24
|
+
'before' => 'The :attribute must be a date before :date.',
|
25
|
+
'before_or_equal' => 'The :attribute must be a date before or equal to :date.',
|
26
|
+
'between' => [
|
27
|
+
'array' => 'The :attribute must have between :min and :max items.',
|
28
|
+
'file' => 'The :attribute must be between :min and :max kilobytes.',
|
29
|
+
'numeric' => 'The :attribute must be between :min and :max.',
|
30
|
+
'string' => 'The :attribute must be between :min and :max characters.',
|
31
|
+
],
|
32
|
+
'boolean' => 'The :attribute field must be true or false.',
|
33
|
+
'confirmed' => 'The :attribute confirmation does not match.',
|
34
|
+
'current_password' => 'The password is incorrect.',
|
35
|
+
'date' => 'The :attribute is not a valid date.',
|
36
|
+
'date_equals' => 'The :attribute must be a date equal to :date.',
|
37
|
+
'date_format' => 'The :attribute does not match the format :format.',
|
38
|
+
'declined' => 'The :attribute must be declined.',
|
39
|
+
'declined_if' => 'The :attribute must be declined when :other is :value.',
|
40
|
+
'different' => 'The :attribute and :other must be different.',
|
41
|
+
'digits' => 'The :attribute must be :digits digits.',
|
42
|
+
'digits_between' => 'The :attribute must be between :min and :max digits.',
|
43
|
+
'dimensions' => 'The :attribute has invalid image dimensions.',
|
44
|
+
'distinct' => 'The :attribute field has a duplicate value.',
|
45
|
+
'doesnt_end_with' => 'The :attribute may not end with one of the following: :values.',
|
46
|
+
'doesnt_start_with' => 'The :attribute may not start with one of the following: :values.',
|
47
|
+
'email' => 'The :attribute must be a valid email address.',
|
48
|
+
'ends_with' => 'The :attribute must end with one of the following: :values.',
|
49
|
+
'enum' => 'The selected :attribute is invalid.',
|
50
|
+
'exists' => 'The selected :attribute is invalid.',
|
51
|
+
'file' => 'The :attribute must be a file.',
|
52
|
+
'filled' => 'The :attribute field must have a value.',
|
53
|
+
'gt' => [
|
54
|
+
'array' => 'The :attribute must have more than :value items.',
|
55
|
+
'file' => 'The :attribute must be greater than :value kilobytes.',
|
56
|
+
'numeric' => 'The :attribute must be greater than :value.',
|
57
|
+
'string' => 'The :attribute must be greater than :value characters.',
|
58
|
+
],
|
59
|
+
'gte' => [
|
60
|
+
'array' => 'The :attribute must have :value items or more.',
|
61
|
+
'file' => 'The :attribute must be greater than or equal to :value kilobytes.',
|
62
|
+
'numeric' => 'The :attribute must be greater than or equal to :value.',
|
63
|
+
'string' => 'The :attribute must be greater than or equal to :value characters.',
|
64
|
+
],
|
65
|
+
'image' => 'The :attribute must be an image.',
|
66
|
+
'in' => 'The selected :attribute is invalid.',
|
67
|
+
'in_array' => 'The :attribute field does not exist in :other.',
|
68
|
+
'integer' => 'The :attribute must be an integer.',
|
69
|
+
'ip' => 'The :attribute must be a valid IP address.',
|
70
|
+
'ipv4' => 'The :attribute must be a valid IPv4 address.',
|
71
|
+
'ipv6' => 'The :attribute must be a valid IPv6 address.',
|
72
|
+
'json' => 'The :attribute must be a valid JSON string.',
|
73
|
+
'lt' => [
|
74
|
+
'array' => 'The :attribute must have less than :value items.',
|
75
|
+
'file' => 'The :attribute must be less than :value kilobytes.',
|
76
|
+
'numeric' => 'The :attribute must be less than :value.',
|
77
|
+
'string' => 'The :attribute must be less than :value characters.',
|
78
|
+
],
|
79
|
+
'lte' => [
|
80
|
+
'array' => 'The :attribute must not have more than :value items.',
|
81
|
+
'file' => 'The :attribute must be less than or equal to :value kilobytes.',
|
82
|
+
'numeric' => 'The :attribute must be less than or equal to :value.',
|
83
|
+
'string' => 'The :attribute must be less than or equal to :value characters.',
|
84
|
+
],
|
85
|
+
'mac_address' => 'The :attribute must be a valid MAC address.',
|
86
|
+
'max' => [
|
87
|
+
'array' => 'The :attribute must not have more than :max items.',
|
88
|
+
'file' => 'The :attribute must not be greater than :max kilobytes.',
|
89
|
+
'numeric' => 'The :attribute must not be greater than :max.',
|
90
|
+
'string' => 'The :attribute must not be greater than :max characters.',
|
91
|
+
],
|
92
|
+
'mimes' => 'The :attribute must be a file of type: :values.',
|
93
|
+
'mimetypes' => 'The :attribute must be a file of type: :values.',
|
94
|
+
'min' => [
|
95
|
+
'array' => 'The :attribute must have at least :min items.',
|
96
|
+
'file' => 'The :attribute must be at least :min kilobytes.',
|
97
|
+
'numeric' => 'The :attribute must be at least :min.',
|
98
|
+
'string' => 'The :attribute must be at least :min characters.',
|
99
|
+
],
|
100
|
+
'multiple_of' => 'The :attribute must be a multiple of :value.',
|
101
|
+
'not_in' => 'The selected :attribute is invalid.',
|
102
|
+
'not_regex' => 'The :attribute format is invalid.',
|
103
|
+
'numeric' => 'The :attribute must be a number.',
|
104
|
+
'password' => [
|
105
|
+
'letters' => 'The :attribute must contain at least one letter.',
|
106
|
+
'mixed' => 'The :attribute must contain at least one uppercase and one lowercase letter.',
|
107
|
+
'numbers' => 'The :attribute must contain at least one number.',
|
108
|
+
'symbols' => 'The :attribute must contain at least one symbol.',
|
109
|
+
'uncompromised' =>
|
110
|
+
'The given :attribute has appeared in a data leak. Please choose a different :attribute.',
|
111
|
+
],
|
112
|
+
'present' => 'The :attribute field must be present.',
|
113
|
+
'prohibited' => 'The :attribute field is prohibited.',
|
114
|
+
'prohibited_if' => 'The :attribute field is prohibited when :other is :value.',
|
115
|
+
'prohibited_unless' => 'The :attribute field is prohibited unless :other is in :values.',
|
116
|
+
'prohibits' => 'The :attribute field prohibits :other from being present.',
|
117
|
+
'regex' => 'The :attribute format is invalid.',
|
118
|
+
'required' => 'The :attribute field is required.',
|
119
|
+
'required_array_keys' => 'The :attribute field must contain entries for: :values.',
|
120
|
+
'required_if' => 'The :attribute field is required when :other is :value.',
|
121
|
+
'required_unless' => 'The :attribute field is required unless :other is in :values.',
|
122
|
+
'required_with' => 'The :attribute field is required when :values is present.',
|
123
|
+
'required_with_all' => 'The :attribute field is required when :values are present.',
|
124
|
+
'required_without' => 'The :attribute field is required when :values is not present.',
|
125
|
+
'required_without_all' => 'The :attribute field is required when none of :values are present.',
|
126
|
+
'same' => 'The :attribute and :other must match.',
|
127
|
+
'size' => [
|
128
|
+
'array' => 'The :attribute must contain :size items.',
|
129
|
+
'file' => 'The :attribute must be :size kilobytes.',
|
130
|
+
'numeric' => 'The :attribute must be :size.',
|
131
|
+
'string' => 'The :attribute must be :size characters.',
|
132
|
+
],
|
133
|
+
'starts_with' => 'The :attribute must start with one of the following: :values.',
|
134
|
+
'string' => 'The :attribute must be a string.',
|
135
|
+
'timezone' => 'The :attribute must be a valid timezone.',
|
136
|
+
'token_failed' => 'Invalid code',
|
137
|
+
'unique' => 'The :attribute has already been taken.',
|
138
|
+
'uploaded' => 'The :attribute failed to upload.',
|
139
|
+
'url' => 'The :attribute must be a valid URL.',
|
140
|
+
'uuid' => 'The :attribute must be a valid UUID.',
|
141
|
+
|
142
|
+
/*
|
143
|
+
|--------------------------------------------------------------------------
|
144
|
+
| Custom Validation Language Lines
|
145
|
+
|--------------------------------------------------------------------------
|
146
|
+
|
|
147
|
+
| Here you may specify custom validation messages for attributes using the
|
148
|
+
| convention "attribute.rule" to name the lines. This makes it quick to
|
149
|
+
| specify a specific custom language line for a given attribute rule.
|
150
|
+
|
|
151
|
+
*/
|
152
|
+
|
153
|
+
'custom' => [],
|
154
|
+
|
155
|
+
/*
|
156
|
+
|--------------------------------------------------------------------------
|
157
|
+
| Custom Validation Attributes
|
158
|
+
|--------------------------------------------------------------------------
|
159
|
+
|
|
160
|
+
| The following language lines are used to swap our attribute placeholder
|
161
|
+
| with something more reader friendly such as "E-Mail Address" instead
|
162
|
+
| of "email". This simply helps us make our message more expressive.
|
163
|
+
|
|
164
|
+
*/
|
165
|
+
|
166
|
+
'attributes' => [],
|
167
|
+
];
|