@parallelvoidshaurya/hello-world-introduction-sdk 0.0.0-stage → 1.0.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.
package/README.md CHANGED
@@ -1,3 +1,37 @@
1
- # Temporary Holding Version
1
+ # @parallelvoidshaurya/hello-world-introduction-sdk
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ A simple React UI SDK component built with TypeScript.
4
+
5
+ ## Installation
6
+
7
+ ```bash
8
+ npm install @parallelvoidshaurya/hello-world-introduction-sdk
9
+ ```
10
+
11
+ *(Make sure your project has React 17+ or 18+ installed)*
12
+
13
+ ## Usage
14
+
15
+ ```tsx
16
+ import React from 'react';
17
+ import { HelloWorldIntroduction } from '@parallelvoidshaurya/hello-world-introduction-sdk';
18
+
19
+ export default function App() {
20
+ return (
21
+ <div>
22
+ {/* Default usage */}
23
+ <HelloWorldIntroduction />
24
+
25
+ {/* With custom name and color */}
26
+ <HelloWorldIntroduction name="Shaurya" color="#16a34a" />
27
+ </div>
28
+ );
29
+ }
30
+ ```
31
+
32
+ ## Props
33
+
34
+ | Prop | Type | Default | Description |
35
+ |------|------|---------|-------------|
36
+ | `name` | `string` | `'World'` | The name displayed in the greeting |
37
+ | `color` | `string` | `'#2563eb'` | Accent border and text color |
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ export interface HelloWorldProps {
3
+ name?: string;
4
+ color?: string;
5
+ }
6
+ export declare const HelloWorldIntroduction: React.FC<HelloWorldProps>;
@@ -0,0 +1,2 @@
1
+ export { HelloWorldIntroduction } from "./HelloWorldIntroduction";
2
+ export type { HelloWorldProps } from "./HelloWorldIntroduction";
package/dist/index.js ADDED
@@ -0,0 +1,57 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: true });
9
+ };
10
+ var __copyProps = (to, from, except, desc) => {
11
+ if (from && typeof from === "object" || typeof from === "function") {
12
+ for (let key of __getOwnPropNames(from))
13
+ if (!__hasOwnProp.call(to, key) && key !== except)
14
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
15
+ }
16
+ return to;
17
+ };
18
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
19
+
20
+ // src/index.ts
21
+ var index_exports = {};
22
+ __export(index_exports, {
23
+ HelloWorldIntroduction: () => HelloWorldIntroduction
24
+ });
25
+ module.exports = __toCommonJS(index_exports);
26
+
27
+ // src/HelloWorldIntroduction.tsx
28
+ var import_jsx_runtime = require("react/jsx-runtime");
29
+ var HelloWorldIntroduction = ({
30
+ name = "World",
31
+ color = "#2563eb"
32
+ }) => {
33
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
34
+ "div",
35
+ {
36
+ style: {
37
+ padding: "16px 24px",
38
+ borderRadius: "8px",
39
+ backgroundColor: "#f8fafc",
40
+ border: `2px solid ${color}`,
41
+ color,
42
+ fontFamily: "sans-serif",
43
+ fontWeight: 600,
44
+ display: "inline-block"
45
+ },
46
+ children: [
47
+ "Hello, ",
48
+ name,
49
+ "! \u{1F44B} (from my NPM SDK)"
50
+ ]
51
+ }
52
+ );
53
+ };
54
+ // Annotate the CommonJS export names for ESM import in node:
55
+ 0 && (module.exports = {
56
+ HelloWorldIntroduction
57
+ });
package/dist/index.mjs ADDED
@@ -0,0 +1,30 @@
1
+ // src/HelloWorldIntroduction.tsx
2
+ import { jsxs } from "react/jsx-runtime";
3
+ var HelloWorldIntroduction = ({
4
+ name = "World",
5
+ color = "#2563eb"
6
+ }) => {
7
+ return /* @__PURE__ */ jsxs(
8
+ "div",
9
+ {
10
+ style: {
11
+ padding: "16px 24px",
12
+ borderRadius: "8px",
13
+ backgroundColor: "#f8fafc",
14
+ border: `2px solid ${color}`,
15
+ color,
16
+ fontFamily: "sans-serif",
17
+ fontWeight: 600,
18
+ display: "inline-block"
19
+ },
20
+ children: [
21
+ "Hello, ",
22
+ name,
23
+ "! \u{1F44B} (from my NPM SDK)"
24
+ ]
25
+ }
26
+ );
27
+ };
28
+ export {
29
+ HelloWorldIntroduction
30
+ };
package/package.json CHANGED
@@ -1,6 +1,34 @@
1
1
  {
2
2
  "name": "@parallelvoidshaurya/hello-world-introduction-sdk",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
3
+ "version": "1.0.0",
4
+ "description": "A simple Hello World React SDK",
5
+ "main": "./dist/index.js",
6
+ "module": "./dist/index.mjs",
7
+ "types": "./dist/index.d.ts",
8
+ "exports": {
9
+ ".": {
10
+ "types": "./dist/index.d.ts",
11
+ "import": "./dist/index.mjs",
12
+ "require": "./dist/index.js"
13
+ }
14
+ },
15
+ "files": [
16
+ "dist"
17
+ ],
18
+ "scripts": {
19
+ "build": "tsup src/index.ts --format cjs,esm --clean --external react && tsc --emitDeclarationOnly --outDir dist",
20
+ "prepublishOnly": "npm run build"
21
+ },
22
+ "peerDependencies": {
23
+ "react": ">=17.0.0",
24
+ "react-dom": ">=17.0.0"
25
+ },
26
+ "devDependencies": {
27
+ "@types/react": "^18.3.0",
28
+ "@types/react-dom": "^18.3.0",
29
+ "react": "^18.3.0",
30
+ "react-dom": "^18.3.0",
31
+ "tsup": "^8.0.0",
32
+ "typescript": "^5.0.0"
33
+ }
6
34
  }