package-installer-cli 1.3.2 โ 1.4.0
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.
- checksums.yaml +4 -4
- data/dist/commands/email.js +1140 -0
- data/dist/email-templates/bugReport.js +108 -0
- data/dist/email-templates/collectors/bugReport.js +41 -0
- data/dist/email-templates/collectors/common.js +56 -0
- data/dist/email-templates/collectors/docs.js +41 -0
- data/dist/email-templates/collectors/featureRequest.js +47 -0
- data/dist/email-templates/collectors/improvement.js +52 -0
- data/dist/email-templates/collectors/index.js +8 -0
- data/dist/email-templates/collectors/question.js +31 -0
- data/dist/email-templates/collectors/templateRequest.js +53 -0
- data/dist/email-templates/docs.js +111 -0
- data/dist/email-templates/featureRequest.js +111 -0
- data/dist/email-templates/generator.js +62 -0
- data/dist/email-templates/improvement.js +121 -0
- data/dist/email-templates/index.js +14 -0
- data/dist/email-templates/question.js +101 -0
- data/dist/email-templates/styles.js +168 -0
- data/dist/email-templates/templateRequest.js +120 -0
- data/dist/email-templates/testEmail.js +56 -0
- data/dist/email-templates/types.js +1 -0
- data/dist/index.js +29 -1
- data/dist/utils/featureInstaller.js +4 -11
- data/features/ai/ai.json +547 -0
- data/features/analytics/analytics.json +4 -0
- data/features/auth/auth.json +473 -0
- data/features/auth/auth0/django/backend/apiexample/urls.py +10 -0
- data/features/auth/auth0/django/backend/apiexample/validator.py +21 -0
- data/features/auth/auth0/django/backend/apiexample/views.py +30 -0
- data/features/auth/auth0/django/backend/requirements.txt +4 -0
- data/features/auth/auth0/django/web-app/requirements.txt +4 -0
- data/features/auth/auth0/django/web-app/webappexample/settings.py +28 -0
- data/features/auth/auth0/django/web-app/webappexample/templates/index.html +16 -0
- data/features/auth/auth0/django/web-app/webappexample/urls.py +10 -0
- data/features/auth/auth0/django/web-app/webappexample/views.py +52 -0
- data/features/auth/auth0/go/backend/go.mod +8 -0
- data/features/auth/auth0/go/backend/main.go +60 -0
- data/features/auth/auth0/go/backend/middleware/jwt.go +81 -0
- data/features/auth/auth0/go/web-app/auth.go +56 -0
- data/features/auth/auth0/go/web-app/callback.go +52 -0
- data/features/auth/auth0/go/web-app/go.mod +11 -0
- data/features/auth/auth0/go/web-app/isAuthenticated.go +20 -0
- data/features/auth/auth0/go/web-app/login.go +47 -0
- data/features/auth/auth0/go/web-app/logout.go +38 -0
- data/features/auth/auth0/go/web-app/main.go +31 -0
- data/features/auth/auth0/go/web-app/router.go +44 -0
- data/features/auth/auth0/go/web-app/user.go +18 -0
- data/features/auth/auth0/ruby-on-rails/backend/Gemfile +1 -0
- data/features/auth/auth0/ruby-on-rails/backend/app/controllers/application_controller.rb +5 -0
- data/features/auth/auth0/ruby-on-rails/backend/app/controllers/concern/secured.rb +60 -0
- data/features/auth/auth0/ruby-on-rails/backend/app/controllers/private_controller.rb +6 -0
- data/features/auth/auth0/ruby-on-rails/backend/app/controllers/public-controller.rb +6 -0
- data/features/auth/auth0/ruby-on-rails/backend/app/lib/auth0_client.rb +59 -0
- data/features/auth/auth0/ruby-on-rails/web-app/Gemfile +2 -0
- data/features/auth/auth0/ruby-on-rails/web-app/auth0_controller.rb +41 -0
- data/features/auth/auth0/ruby-on-rails/web-app/config/auth0.yml +4 -0
- data/features/auth/auth0/ruby-on-rails/web-app/config/initializers/auth0.rb +14 -0
- data/features/auth/auth0/ruby-on-rails/web-app/config/routes.rb +6 -0
- data/features/auth/auth0/ruby-on-rails/web-app/config/secured.rb +11 -0
- data/features/auth/clerk/go/clerk_client.go +28 -0
- data/features/auth/clerk/go/go.mod +5 -0
- data/features/auth/clerk/go/main.go +82 -0
- data/features/auth/clerk/nextjs/typescript/app/layout.tsx +2 -2
- data/features/auth/clerk/ruby-on-rails/Gemfile +1 -0
- data/features/auth/clerk/ruby-on-rails/app.rb +50 -0
- data/features/auth/clerk/ruby-on-rails/config/initializers/clerk.rb +4 -0
- data/features/aws/aws.json +5207 -0
- data/features/database/database.json +246 -0
- data/features/docker/docker.json +108 -0
- data/features/features.json +44 -7321
- data/features/gitignore/gitignore.json +61 -0
- data/features/monitoring/monitoring.json +5 -0
- data/features/payment/payment.json +347 -0
- data/features/storage/storage.json +371 -0
- data/features/testing/jest/angularjs/typescript/tests/angularjs.test.ts +12 -0
- data/features/testing/jest/expressjs/javascript/tests/expressjs.test.js +10 -0
- data/features/testing/jest/expressjs/typescript/tests/expressjs.test.ts +10 -0
- data/features/testing/jest/nestjs/typescript/tests/nestjs.test.ts +10 -0
- data/features/testing/jest/nextjs/javascript/tests/nextjs.test.js +10 -0
- data/features/testing/jest/nextjs/typescript/tests/nextjs.test.ts +10 -0
- data/features/testing/jest/nuxtjs/typescript/tests/nuxtjs.test.ts +9 -0
- data/features/testing/jest/reactjs/javascript/tests/reactjs.test.js +10 -0
- data/features/testing/jest/reactjs/typescript/tests/reactjs.test.ts +10 -0
- data/features/testing/jest/reactjs-expressjs-shadcn/javascript/tests/reactjs.expressjs.shadcn.test.js +16 -0
- data/features/testing/jest/reactjs-expressjs-shadcn/typescript/tests/reactjs.expressjs.shadcn.test.ts +16 -0
- data/features/testing/jest/reactjs-nestjs-shadcn/typescript/tests/reactjs.nestjs.shadcn.test.ts +14 -0
- data/features/testing/jest/remixjs/typescript/tests/remixjs.test.ts +9 -0
- data/features/testing/jest/vuejs/javascript/tests/vuejs.test.ts +9 -0
- data/features/testing/jest/vuejs/typescript/tests/vuejs.test.ts +9 -0
- data/features/testing/testing.json +102 -0
- data/features/ui/ui.json +91 -0
- metadata +88 -8
- data/features/testing/jest/angularjs/tests/angularjs.test.js +0 -12
- data/features/testing/jest/expressjs/tests/javascript/expressjs.test.js +0 -12
- data/features/testing/jest/expressjs/tests/typescript/expressjs.test.ts +0 -12
- data/features/testing/jest/go/tests/go.test.js +0 -12
- data/features/testing/jest/nextjs/tests/javascript/nextjs.test.js +0 -12
- data/features/testing/jest/nextjs/tests/typescript/nextjs.test.ts +0 -12
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import { generateBugReportTemplate } from './bugReport.js';
|
|
2
|
+
import { generateFeatureRequestTemplate } from './featureRequest.js';
|
|
3
|
+
import { generateTemplateRequestTemplate } from './templateRequest.js';
|
|
4
|
+
import { generateQuestionTemplate } from './question.js';
|
|
5
|
+
import { generateImprovementTemplate } from './improvement.js';
|
|
6
|
+
import { generateDocsTemplate } from './docs.js';
|
|
7
|
+
/**
|
|
8
|
+
* Generate HTML email template using modular template functions
|
|
9
|
+
*/
|
|
10
|
+
export function generateEmailTemplate(category, data, systemInfo) {
|
|
11
|
+
// Convert data to TemplateData interface
|
|
12
|
+
const templateData = {
|
|
13
|
+
title: data.title,
|
|
14
|
+
description: data.description,
|
|
15
|
+
// Bug report specific
|
|
16
|
+
steps: data.steps,
|
|
17
|
+
expected: data.expected,
|
|
18
|
+
actual: data.actual,
|
|
19
|
+
// Feature request specific
|
|
20
|
+
useCase: data.useCase,
|
|
21
|
+
solution: data.solution,
|
|
22
|
+
benefits: data.benefits,
|
|
23
|
+
implementation: data.implementation,
|
|
24
|
+
// Template request specific
|
|
25
|
+
framework: data.framework,
|
|
26
|
+
features: data.features,
|
|
27
|
+
similar: data.similar,
|
|
28
|
+
// Question specific
|
|
29
|
+
tried: data.tried,
|
|
30
|
+
context: data.context,
|
|
31
|
+
// Improvement specific
|
|
32
|
+
currentBehavior: data.current,
|
|
33
|
+
proposedBehavior: data.description,
|
|
34
|
+
// Documentation specific
|
|
35
|
+
docSection: data.section,
|
|
36
|
+
issue: data.problems,
|
|
37
|
+
suggestion: data.suggestions,
|
|
38
|
+
// Common fields
|
|
39
|
+
priority: data.priority,
|
|
40
|
+
additional: data.additional,
|
|
41
|
+
name: data.name,
|
|
42
|
+
email: data.email
|
|
43
|
+
};
|
|
44
|
+
// Use appropriate template function based on category
|
|
45
|
+
switch (category) {
|
|
46
|
+
case 'bug':
|
|
47
|
+
return generateBugReportTemplate(templateData, systemInfo);
|
|
48
|
+
case 'feature':
|
|
49
|
+
return generateFeatureRequestTemplate(templateData, systemInfo);
|
|
50
|
+
case 'template':
|
|
51
|
+
return generateTemplateRequestTemplate(templateData, systemInfo);
|
|
52
|
+
case 'question':
|
|
53
|
+
return generateQuestionTemplate(templateData, systemInfo);
|
|
54
|
+
case 'improvement':
|
|
55
|
+
return generateImprovementTemplate(templateData, systemInfo);
|
|
56
|
+
case 'docs':
|
|
57
|
+
return generateDocsTemplate(templateData, systemInfo);
|
|
58
|
+
default:
|
|
59
|
+
// Fallback to question template for unknown categories
|
|
60
|
+
return generateQuestionTemplate(templateData, systemInfo);
|
|
61
|
+
}
|
|
62
|
+
}
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
import { EMAIL_CSS } from './styles.js';
|
|
2
|
+
export function generateImprovementTemplate(data, systemInfo) {
|
|
3
|
+
return {
|
|
4
|
+
subject: `[Package Installer CLI] ๐ Improvement Suggestion: ${data.title}`,
|
|
5
|
+
htmlBody: `
|
|
6
|
+
${EMAIL_CSS}
|
|
7
|
+
<body>
|
|
8
|
+
<div class="email-container">
|
|
9
|
+
<div class="header improvement">
|
|
10
|
+
<span class="emoji">๐</span>
|
|
11
|
+
<h1>Improvement Suggestion</h1>
|
|
12
|
+
<p style="margin: 5px 0 0 0; opacity: 0.9;">Package Installer CLI</p>
|
|
13
|
+
</div>
|
|
14
|
+
|
|
15
|
+
<div class="content">
|
|
16
|
+
<div class="section">
|
|
17
|
+
<h3>Improvement Title</h3>
|
|
18
|
+
<p><strong>${data.title}</strong></p>
|
|
19
|
+
</div>
|
|
20
|
+
|
|
21
|
+
<div class="section">
|
|
22
|
+
<h3>Description</h3>
|
|
23
|
+
<p>${data.description}</p>
|
|
24
|
+
</div>
|
|
25
|
+
|
|
26
|
+
${data.currentBehavior ? `
|
|
27
|
+
<div class="section">
|
|
28
|
+
<h3>Current Behavior</h3>
|
|
29
|
+
<p>${data.currentBehavior}</p>
|
|
30
|
+
</div>
|
|
31
|
+
` : ''}
|
|
32
|
+
|
|
33
|
+
${data.proposedBehavior ? `
|
|
34
|
+
<div class="section">
|
|
35
|
+
<h3>Proposed Behavior</h3>
|
|
36
|
+
<p>${data.proposedBehavior}</p>
|
|
37
|
+
</div>
|
|
38
|
+
` : ''}
|
|
39
|
+
|
|
40
|
+
${data.benefits ? `
|
|
41
|
+
<div class="section">
|
|
42
|
+
<h3>Benefits</h3>
|
|
43
|
+
<p>${data.benefits}</p>
|
|
44
|
+
</div>
|
|
45
|
+
` : ''}
|
|
46
|
+
|
|
47
|
+
${data.implementation ? `
|
|
48
|
+
<div class="section">
|
|
49
|
+
<h3>Implementation Ideas</h3>
|
|
50
|
+
<p>${data.implementation}</p>
|
|
51
|
+
</div>
|
|
52
|
+
` : ''}
|
|
53
|
+
|
|
54
|
+
${data.additional ? `
|
|
55
|
+
<div class="section">
|
|
56
|
+
<h3>Additional Information</h3>
|
|
57
|
+
<p>${data.additional}</p>
|
|
58
|
+
</div>
|
|
59
|
+
` : ''}
|
|
60
|
+
|
|
61
|
+
<div class="system-info">
|
|
62
|
+
<strong>System Information:</strong><br>
|
|
63
|
+
- OS: ${systemInfo.platform} (${systemInfo.arch})<br>
|
|
64
|
+
- Node.js: ${systemInfo.nodeVersion}<br>
|
|
65
|
+
- CLI Version: ${systemInfo.cliVersion}<br>
|
|
66
|
+
- Working Directory: ${systemInfo.workingDirectory}
|
|
67
|
+
</div>
|
|
68
|
+
|
|
69
|
+
${data.name || data.email ? `
|
|
70
|
+
<div class="contact-info">
|
|
71
|
+
<strong>Contact Information:</strong><br>
|
|
72
|
+
${data.name ? `Name: ${data.name}<br>` : ''}
|
|
73
|
+
${data.email ? `Email: ${data.email}` : ''}
|
|
74
|
+
</div>
|
|
75
|
+
` : ''}
|
|
76
|
+
</div>
|
|
77
|
+
|
|
78
|
+
<div class="footer">
|
|
79
|
+
<div class="timestamp">Suggested at: ${systemInfo.timestamp}</div>
|
|
80
|
+
<p style="margin: 10px 0 0 0;">Thank you for helping make Package Installer CLI better! ๐</p>
|
|
81
|
+
</div>
|
|
82
|
+
</div>
|
|
83
|
+
</body>
|
|
84
|
+
`,
|
|
85
|
+
plainBody: `Hi Shariq,
|
|
86
|
+
|
|
87
|
+
I have an improvement suggestion for Package Installer CLI.
|
|
88
|
+
|
|
89
|
+
Improvement Title: ${data.title}
|
|
90
|
+
|
|
91
|
+
Description:
|
|
92
|
+
${data.description}
|
|
93
|
+
|
|
94
|
+
Current Behavior:
|
|
95
|
+
${data.currentBehavior || 'Not described'}
|
|
96
|
+
|
|
97
|
+
Proposed Behavior:
|
|
98
|
+
${data.proposedBehavior || 'Not described'}
|
|
99
|
+
|
|
100
|
+
Benefits:
|
|
101
|
+
${data.benefits || 'Not provided'}
|
|
102
|
+
|
|
103
|
+
Implementation Ideas:
|
|
104
|
+
${data.implementation || 'Not provided'}
|
|
105
|
+
|
|
106
|
+
Additional Information:
|
|
107
|
+
${data.additional || 'None'}
|
|
108
|
+
|
|
109
|
+
System Information:
|
|
110
|
+
- OS: ${systemInfo.platform} (${systemInfo.arch})
|
|
111
|
+
- Node.js: ${systemInfo.nodeVersion}
|
|
112
|
+
- CLI Version: ${systemInfo.cliVersion}
|
|
113
|
+
- Working Directory: ${systemInfo.workingDirectory}
|
|
114
|
+
|
|
115
|
+
Suggested at: ${systemInfo.timestamp}
|
|
116
|
+
|
|
117
|
+
Best regards,
|
|
118
|
+
${data.name || 'Anonymous User'}
|
|
119
|
+
${data.email ? `Contact: ${data.email}` : ''}`
|
|
120
|
+
};
|
|
121
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
// Main exports for email templates
|
|
2
|
+
export * from './types.js';
|
|
3
|
+
export * from './styles.js';
|
|
4
|
+
// Template generators
|
|
5
|
+
export { generateBugReportTemplate } from './bugReport.js';
|
|
6
|
+
export { generateFeatureRequestTemplate } from './featureRequest.js';
|
|
7
|
+
export { generateTemplateRequestTemplate } from './templateRequest.js';
|
|
8
|
+
export { generateQuestionTemplate } from './question.js';
|
|
9
|
+
export { generateImprovementTemplate } from './improvement.js';
|
|
10
|
+
export { generateDocsTemplate } from './docs.js';
|
|
11
|
+
export { generateTestEmailTemplate } from './testEmail.js';
|
|
12
|
+
export { generateEmailTemplate } from './generator.js';
|
|
13
|
+
// Data collectors
|
|
14
|
+
export * from './collectors/index.js';
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
import { EMAIL_CSS } from './styles.js';
|
|
2
|
+
export function generateQuestionTemplate(data, systemInfo) {
|
|
3
|
+
return {
|
|
4
|
+
subject: `[Package Installer CLI] โ Question: ${data.title}`,
|
|
5
|
+
htmlBody: `
|
|
6
|
+
${EMAIL_CSS}
|
|
7
|
+
<body>
|
|
8
|
+
<div class="email-container">
|
|
9
|
+
<div class="header question">
|
|
10
|
+
<span class="emoji">โ</span>
|
|
11
|
+
<h1>Question</h1>
|
|
12
|
+
<p style="margin: 5px 0 0 0; opacity: 0.9;">Package Installer CLI</p>
|
|
13
|
+
</div>
|
|
14
|
+
|
|
15
|
+
<div class="content">
|
|
16
|
+
<div class="section">
|
|
17
|
+
<h3>Question Title</h3>
|
|
18
|
+
<p><strong>${data.title}</strong></p>
|
|
19
|
+
</div>
|
|
20
|
+
|
|
21
|
+
<div class="section">
|
|
22
|
+
<h3>Question Details</h3>
|
|
23
|
+
<p>${data.description}</p>
|
|
24
|
+
</div>
|
|
25
|
+
|
|
26
|
+
${data.context ? `
|
|
27
|
+
<div class="section">
|
|
28
|
+
<h3>Context</h3>
|
|
29
|
+
<p>${data.context}</p>
|
|
30
|
+
</div>
|
|
31
|
+
` : ''}
|
|
32
|
+
|
|
33
|
+
${data.tried ? `
|
|
34
|
+
<div class="section">
|
|
35
|
+
<h3>What I've Tried</h3>
|
|
36
|
+
<p>${data.tried}</p>
|
|
37
|
+
</div>
|
|
38
|
+
` : ''}
|
|
39
|
+
|
|
40
|
+
${data.additional ? `
|
|
41
|
+
<div class="section">
|
|
42
|
+
<h3>Additional Information</h3>
|
|
43
|
+
<p>${data.additional}</p>
|
|
44
|
+
</div>
|
|
45
|
+
` : ''}
|
|
46
|
+
|
|
47
|
+
<div class="system-info">
|
|
48
|
+
<strong>System Information:</strong><br>
|
|
49
|
+
- OS: ${systemInfo.platform} (${systemInfo.arch})<br>
|
|
50
|
+
- Node.js: ${systemInfo.nodeVersion}<br>
|
|
51
|
+
- CLI Version: ${systemInfo.cliVersion}<br>
|
|
52
|
+
- Working Directory: ${systemInfo.workingDirectory}
|
|
53
|
+
</div>
|
|
54
|
+
|
|
55
|
+
${data.name || data.email ? `
|
|
56
|
+
<div class="contact-info">
|
|
57
|
+
<strong>Contact Information:</strong><br>
|
|
58
|
+
${data.name ? `Name: ${data.name}<br>` : ''}
|
|
59
|
+
${data.email ? `Email: ${data.email}` : ''}
|
|
60
|
+
</div>
|
|
61
|
+
` : ''}
|
|
62
|
+
</div>
|
|
63
|
+
|
|
64
|
+
<div class="footer">
|
|
65
|
+
<div class="timestamp">Asked at: ${systemInfo.timestamp}</div>
|
|
66
|
+
<p style="margin: 10px 0 0 0;">We'll get back to you soon! ๐ฌ</p>
|
|
67
|
+
</div>
|
|
68
|
+
</div>
|
|
69
|
+
</body>
|
|
70
|
+
`,
|
|
71
|
+
plainBody: `Hi Shariq,
|
|
72
|
+
|
|
73
|
+
I have a question about Package Installer CLI.
|
|
74
|
+
|
|
75
|
+
Question Title: ${data.title}
|
|
76
|
+
|
|
77
|
+
Question Details:
|
|
78
|
+
${data.description}
|
|
79
|
+
|
|
80
|
+
Context:
|
|
81
|
+
${data.context || 'Not provided'}
|
|
82
|
+
|
|
83
|
+
What I've Tried:
|
|
84
|
+
${data.tried || 'Not provided'}
|
|
85
|
+
|
|
86
|
+
Additional Information:
|
|
87
|
+
${data.additional || 'None'}
|
|
88
|
+
|
|
89
|
+
System Information:
|
|
90
|
+
- OS: ${systemInfo.platform} (${systemInfo.arch})
|
|
91
|
+
- Node.js: ${systemInfo.nodeVersion}
|
|
92
|
+
- CLI Version: ${systemInfo.cliVersion}
|
|
93
|
+
- Working Directory: ${systemInfo.workingDirectory}
|
|
94
|
+
|
|
95
|
+
Asked at: ${systemInfo.timestamp}
|
|
96
|
+
|
|
97
|
+
Best regards,
|
|
98
|
+
${data.name || 'Anonymous User'}
|
|
99
|
+
${data.email ? `Contact: ${data.email}` : ''}`
|
|
100
|
+
};
|
|
101
|
+
}
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Common CSS styles for all email templates
|
|
3
|
+
*/
|
|
4
|
+
export const EMAIL_CSS = `
|
|
5
|
+
<style>
|
|
6
|
+
body {
|
|
7
|
+
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
|
|
8
|
+
line-height: 1.6;
|
|
9
|
+
color: #333;
|
|
10
|
+
max-width: 800px;
|
|
11
|
+
margin: 0 auto;
|
|
12
|
+
padding: 20px;
|
|
13
|
+
background-color: #f8f9fa;
|
|
14
|
+
}
|
|
15
|
+
.email-container {
|
|
16
|
+
background: white;
|
|
17
|
+
border-radius: 12px;
|
|
18
|
+
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
|
|
19
|
+
overflow: hidden;
|
|
20
|
+
}
|
|
21
|
+
.header {
|
|
22
|
+
background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
|
|
23
|
+
color: white;
|
|
24
|
+
padding: 30px;
|
|
25
|
+
text-align: center;
|
|
26
|
+
}
|
|
27
|
+
.header h1 {
|
|
28
|
+
margin: 0;
|
|
29
|
+
font-size: 28px;
|
|
30
|
+
font-weight: 600;
|
|
31
|
+
}
|
|
32
|
+
.header .emoji {
|
|
33
|
+
font-size: 48px;
|
|
34
|
+
display: block;
|
|
35
|
+
margin-bottom: 10px;
|
|
36
|
+
}
|
|
37
|
+
.content {
|
|
38
|
+
padding: 30px;
|
|
39
|
+
}
|
|
40
|
+
.section {
|
|
41
|
+
margin-bottom: 25px;
|
|
42
|
+
padding: 20px;
|
|
43
|
+
background: #f8f9fa;
|
|
44
|
+
border-radius: 8px;
|
|
45
|
+
border-left: 4px solid #667eea;
|
|
46
|
+
}
|
|
47
|
+
.section h3 {
|
|
48
|
+
margin: 0 0 15px 0;
|
|
49
|
+
color: #667eea;
|
|
50
|
+
font-size: 18px;
|
|
51
|
+
font-weight: 600;
|
|
52
|
+
}
|
|
53
|
+
.section p {
|
|
54
|
+
margin: 0;
|
|
55
|
+
white-space: pre-wrap;
|
|
56
|
+
}
|
|
57
|
+
.priority-high {
|
|
58
|
+
border-left-color: #e74c3c;
|
|
59
|
+
}
|
|
60
|
+
.priority-high h3 {
|
|
61
|
+
color: #e74c3c;
|
|
62
|
+
}
|
|
63
|
+
.priority-critical {
|
|
64
|
+
border-left-color: #c0392b;
|
|
65
|
+
background: #fdf2f2;
|
|
66
|
+
}
|
|
67
|
+
.priority-critical h3 {
|
|
68
|
+
color: #c0392b;
|
|
69
|
+
}
|
|
70
|
+
.system-info {
|
|
71
|
+
background: #e8f4f8;
|
|
72
|
+
border: 1px solid #bee5eb;
|
|
73
|
+
border-radius: 8px;
|
|
74
|
+
padding: 15px;
|
|
75
|
+
margin: 20px 0;
|
|
76
|
+
font-family: 'SF Mono', Monaco, 'Cascadia Code', 'Roboto Mono', Consolas, 'Courier New', monospace;
|
|
77
|
+
font-size: 13px;
|
|
78
|
+
color: #495057;
|
|
79
|
+
}
|
|
80
|
+
.steps-list {
|
|
81
|
+
background: white;
|
|
82
|
+
border: 1px solid #dee2e6;
|
|
83
|
+
border-radius: 6px;
|
|
84
|
+
padding: 15px;
|
|
85
|
+
margin: 10px 0;
|
|
86
|
+
}
|
|
87
|
+
.steps-list ol {
|
|
88
|
+
margin: 0;
|
|
89
|
+
padding-left: 20px;
|
|
90
|
+
}
|
|
91
|
+
.steps-list li {
|
|
92
|
+
margin: 8px 0;
|
|
93
|
+
padding: 5px 0;
|
|
94
|
+
}
|
|
95
|
+
.features-list {
|
|
96
|
+
background: white;
|
|
97
|
+
border: 1px solid #dee2e6;
|
|
98
|
+
border-radius: 6px;
|
|
99
|
+
padding: 15px;
|
|
100
|
+
margin: 10px 0;
|
|
101
|
+
}
|
|
102
|
+
.features-list ul {
|
|
103
|
+
margin: 0;
|
|
104
|
+
padding-left: 20px;
|
|
105
|
+
}
|
|
106
|
+
.features-list li {
|
|
107
|
+
margin: 8px 0;
|
|
108
|
+
padding: 5px 0;
|
|
109
|
+
}
|
|
110
|
+
.footer {
|
|
111
|
+
background: #495057;
|
|
112
|
+
color: white;
|
|
113
|
+
padding: 20px 30px;
|
|
114
|
+
text-align: center;
|
|
115
|
+
font-size: 14px;
|
|
116
|
+
}
|
|
117
|
+
.priority-badge {
|
|
118
|
+
display: inline-block;
|
|
119
|
+
padding: 4px 12px;
|
|
120
|
+
border-radius: 20px;
|
|
121
|
+
font-size: 12px;
|
|
122
|
+
font-weight: 600;
|
|
123
|
+
text-transform: uppercase;
|
|
124
|
+
margin-left: 10px;
|
|
125
|
+
}
|
|
126
|
+
.priority-low {
|
|
127
|
+
background: #d1ecf1;
|
|
128
|
+
color: #0c5460;
|
|
129
|
+
}
|
|
130
|
+
.priority-medium {
|
|
131
|
+
background: #fff3cd;
|
|
132
|
+
color: #856404;
|
|
133
|
+
}
|
|
134
|
+
.priority-high-badge {
|
|
135
|
+
background: #f8d7da;
|
|
136
|
+
color: #721c24;
|
|
137
|
+
}
|
|
138
|
+
.priority-critical-badge {
|
|
139
|
+
background: #f5c6cb;
|
|
140
|
+
color: #491217;
|
|
141
|
+
}
|
|
142
|
+
.contact-info {
|
|
143
|
+
background: #e8f5e8;
|
|
144
|
+
border: 1px solid #c3e6cb;
|
|
145
|
+
border-radius: 6px;
|
|
146
|
+
padding: 15px;
|
|
147
|
+
margin: 15px 0;
|
|
148
|
+
}
|
|
149
|
+
.timestamp {
|
|
150
|
+
color: #6c757d;
|
|
151
|
+
font-size: 13px;
|
|
152
|
+
font-style: italic;
|
|
153
|
+
}
|
|
154
|
+
.test-success {
|
|
155
|
+
background: #d4edda;
|
|
156
|
+
border: 1px solid #c3e6cb;
|
|
157
|
+
color: #155724;
|
|
158
|
+
padding: 15px;
|
|
159
|
+
border-radius: 8px;
|
|
160
|
+
margin: 20px 0;
|
|
161
|
+
text-align: center;
|
|
162
|
+
font-weight: 600;
|
|
163
|
+
}
|
|
164
|
+
.header.test {
|
|
165
|
+
background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
|
|
166
|
+
}
|
|
167
|
+
</style>
|
|
168
|
+
`;
|
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
import { EMAIL_CSS } from './styles.js';
|
|
2
|
+
export function generateTemplateRequestTemplate(data, systemInfo) {
|
|
3
|
+
return {
|
|
4
|
+
subject: `[Package Installer CLI] ๐ Template Request: ${data.title}`,
|
|
5
|
+
htmlBody: `
|
|
6
|
+
${EMAIL_CSS}
|
|
7
|
+
<body>
|
|
8
|
+
<div class="email-container">
|
|
9
|
+
<div class="header template">
|
|
10
|
+
<span class="emoji">๐</span>
|
|
11
|
+
<h1>Template Request</h1>
|
|
12
|
+
<p style="margin: 5px 0 0 0; opacity: 0.9;">Package Installer CLI</p>
|
|
13
|
+
</div>
|
|
14
|
+
|
|
15
|
+
<div class="content">
|
|
16
|
+
<div class="section">
|
|
17
|
+
<h3>Template Title</h3>
|
|
18
|
+
<p><strong>${data.title}</strong></p>
|
|
19
|
+
</div>
|
|
20
|
+
|
|
21
|
+
<div class="section">
|
|
22
|
+
<h3>Description</h3>
|
|
23
|
+
<p>${data.description}</p>
|
|
24
|
+
</div>
|
|
25
|
+
|
|
26
|
+
${data.framework ? `
|
|
27
|
+
<div class="section">
|
|
28
|
+
<h3>Framework/Technology</h3>
|
|
29
|
+
<p>${data.framework}</p>
|
|
30
|
+
</div>
|
|
31
|
+
` : ''}
|
|
32
|
+
|
|
33
|
+
${data.features ? `
|
|
34
|
+
<div class="section">
|
|
35
|
+
<h3>Desired Features</h3>
|
|
36
|
+
<p>${data.features}</p>
|
|
37
|
+
</div>
|
|
38
|
+
` : ''}
|
|
39
|
+
|
|
40
|
+
${data.useCase ? `
|
|
41
|
+
<div class="section">
|
|
42
|
+
<h3>Use Case</h3>
|
|
43
|
+
<p>${data.useCase}</p>
|
|
44
|
+
</div>
|
|
45
|
+
` : ''}
|
|
46
|
+
|
|
47
|
+
${data.priority ? `
|
|
48
|
+
<div class="priority-badge ${data.priority}">
|
|
49
|
+
Priority: ${data.priority.charAt(0).toUpperCase() + data.priority.slice(1)}
|
|
50
|
+
</div>
|
|
51
|
+
` : ''}
|
|
52
|
+
|
|
53
|
+
${data.additional ? `
|
|
54
|
+
<div class="section">
|
|
55
|
+
<h3>Additional Information</h3>
|
|
56
|
+
<p>${data.additional}</p>
|
|
57
|
+
</div>
|
|
58
|
+
` : ''}
|
|
59
|
+
|
|
60
|
+
<div class="system-info">
|
|
61
|
+
<strong>System Information:</strong><br>
|
|
62
|
+
- OS: ${systemInfo.platform} (${systemInfo.arch})<br>
|
|
63
|
+
- Node.js: ${systemInfo.nodeVersion}<br>
|
|
64
|
+
- CLI Version: ${systemInfo.cliVersion}<br>
|
|
65
|
+
- Working Directory: ${systemInfo.workingDirectory}
|
|
66
|
+
</div>
|
|
67
|
+
|
|
68
|
+
${data.name || data.email ? `
|
|
69
|
+
<div class="contact-info">
|
|
70
|
+
<strong>Contact Information:</strong><br>
|
|
71
|
+
${data.name ? `Name: ${data.name}<br>` : ''}
|
|
72
|
+
${data.email ? `Email: ${data.email}` : ''}
|
|
73
|
+
</div>
|
|
74
|
+
` : ''}
|
|
75
|
+
</div>
|
|
76
|
+
|
|
77
|
+
<div class="footer">
|
|
78
|
+
<div class="timestamp">Submitted at: ${systemInfo.timestamp}</div>
|
|
79
|
+
<p style="margin: 10px 0 0 0;">Thank you for helping expand Package Installer CLI templates! ๐ฆ</p>
|
|
80
|
+
</div>
|
|
81
|
+
</div>
|
|
82
|
+
</body>
|
|
83
|
+
`,
|
|
84
|
+
plainBody: `Hi Shariq,
|
|
85
|
+
|
|
86
|
+
I have a template request for Package Installer CLI.
|
|
87
|
+
|
|
88
|
+
Template Title: ${data.title}
|
|
89
|
+
|
|
90
|
+
Description:
|
|
91
|
+
${data.description}
|
|
92
|
+
|
|
93
|
+
Framework/Technology:
|
|
94
|
+
${data.framework || 'Not specified'}
|
|
95
|
+
|
|
96
|
+
Desired Features:
|
|
97
|
+
${data.features || 'Not specified'}
|
|
98
|
+
|
|
99
|
+
Use Case:
|
|
100
|
+
${data.useCase || 'Not provided'}
|
|
101
|
+
|
|
102
|
+
Priority:
|
|
103
|
+
${data.priority || 'Not specified'}
|
|
104
|
+
|
|
105
|
+
Additional Information:
|
|
106
|
+
${data.additional || 'None'}
|
|
107
|
+
|
|
108
|
+
System Information:
|
|
109
|
+
- OS: ${systemInfo.platform} (${systemInfo.arch})
|
|
110
|
+
- Node.js: ${systemInfo.nodeVersion}
|
|
111
|
+
- CLI Version: ${systemInfo.cliVersion}
|
|
112
|
+
- Working Directory: ${systemInfo.workingDirectory}
|
|
113
|
+
|
|
114
|
+
Submitted at: ${systemInfo.timestamp}
|
|
115
|
+
|
|
116
|
+
Best regards,
|
|
117
|
+
${data.name || 'Anonymous User'}
|
|
118
|
+
${data.email ? `Contact: ${data.email}` : ''}`
|
|
119
|
+
};
|
|
120
|
+
}
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { EMAIL_CSS } from './styles.js';
|
|
2
|
+
export function generateTestEmailTemplate(systemInfo) {
|
|
3
|
+
return {
|
|
4
|
+
subject: `[Package Installer CLI] ๐งช Test Email - ${systemInfo.timestamp}`,
|
|
5
|
+
htmlBody: `
|
|
6
|
+
${EMAIL_CSS}
|
|
7
|
+
<body>
|
|
8
|
+
<div class="email-container">
|
|
9
|
+
<div class="header test">
|
|
10
|
+
<span class="emoji">๐งช</span>
|
|
11
|
+
<h1>Email Test</h1>
|
|
12
|
+
<p style="margin: 5px 0 0 0; opacity: 0.9;">Package Installer CLI</p>
|
|
13
|
+
</div>
|
|
14
|
+
|
|
15
|
+
<div class="content">
|
|
16
|
+
<div class="test-success">
|
|
17
|
+
โ
Email functionality is working correctly!
|
|
18
|
+
</div>
|
|
19
|
+
|
|
20
|
+
<p>This is a test email from Package Installer CLI to verify that the email system is properly configured and working.</p>
|
|
21
|
+
|
|
22
|
+
<div class="system-info">
|
|
23
|
+
<strong>System Information:</strong><br>
|
|
24
|
+
- OS: ${systemInfo.platform} (${systemInfo.arch})<br>
|
|
25
|
+
- Node.js: ${systemInfo.nodeVersion}<br>
|
|
26
|
+
- CLI Version: ${systemInfo.cliVersion}<br>
|
|
27
|
+
- Working Directory: ${systemInfo.workingDirectory}
|
|
28
|
+
</div>
|
|
29
|
+
|
|
30
|
+
<p>If you receive this email with proper formatting, both HTML and plain text email delivery are functioning correctly.</p>
|
|
31
|
+
</div>
|
|
32
|
+
|
|
33
|
+
<div class="footer">
|
|
34
|
+
<div class="timestamp">Test completed at: ${systemInfo.timestamp}</div>
|
|
35
|
+
<p style="margin: 10px 0 0 0;">Package Installer CLI Email System ๐ง</p>
|
|
36
|
+
</div>
|
|
37
|
+
</div>
|
|
38
|
+
</body>
|
|
39
|
+
`,
|
|
40
|
+
plainBody: `This is a test email from Package Installer CLI.
|
|
41
|
+
|
|
42
|
+
โ
EMAIL TEST SUCCESSFUL โ
|
|
43
|
+
|
|
44
|
+
If you receive this email, the email functionality is working correctly!
|
|
45
|
+
|
|
46
|
+
System Information:
|
|
47
|
+
- OS: ${systemInfo.platform} (${systemInfo.arch})
|
|
48
|
+
- Node.js: ${systemInfo.nodeVersion}
|
|
49
|
+
- CLI Version: ${systemInfo.cliVersion}
|
|
50
|
+
- Working Directory: ${systemInfo.workingDirectory}
|
|
51
|
+
|
|
52
|
+
Test completed at: ${systemInfo.timestamp}
|
|
53
|
+
|
|
54
|
+
Package Installer CLI Email System`
|
|
55
|
+
};
|
|
56
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|