@appcorp/kismaa-web-ui 0.2.15 → 0.2.17

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.
@@ -10,7 +10,7 @@ var react_1 = __importDefault(require("react"));
10
10
  var kismaa_text_input_1 = require("./kismaa-text-input");
11
11
  var kismaa_text_area_1 = require("./kismaa-text-area");
12
12
  var ContactSection = function (_a) {
13
- var breadcrumbs = _a.breadcrumbs, description = _a.description, handleOnChange = _a.handleOnChange, handleOnSubmit = _a.handleOnSubmit, heading = _a.heading, subHeading = _a.subHeading;
13
+ var breadcrumbs = _a.breadcrumbs, comments = _a.comments, description = _a.description, email = _a.email, handleOnChange = _a.handleOnChange, handleOnSubmit = _a.handleOnSubmit, heading = _a.heading, name = _a.name, phone = _a.phone, subHeading = _a.subHeading, subject = _a.subject;
14
14
  return (react_1.default.createElement("section", { className: "kismaa-section-spacing bg-white" },
15
15
  react_1.default.createElement("div", { className: "kismaa-container" },
16
16
  react_1.default.createElement("div", { className: "mb-10" },
@@ -23,12 +23,12 @@ var ContactSection = function (_a) {
23
23
  react_1.default.createElement("div", { className: "mt-2 text-slate-400" },
24
24
  react_1.default.createElement(molecules_1.Typography, { variant: molecules_1.TYPOGRAPHY_VARIANTS.P1 }, description))),
25
25
  react_1.default.createElement("div", { className: "mx-auto mt-16 grid max-w-5xl grid-cols-2 gap-4" },
26
- react_1.default.createElement(kismaa_text_input_1.KismaaTextInput, { handleOnChange: handleOnChange, id: "name", placeholder: "Name", required: true, type: "text" }),
27
- react_1.default.createElement(kismaa_text_input_1.KismaaTextInput, { handleOnChange: handleOnChange, id: "phone", placeholder: "Phone Number", required: true, type: "text" }),
28
- react_1.default.createElement(kismaa_text_input_1.KismaaTextInput, { handleOnChange: handleOnChange, id: "subject", placeholder: "Subject", required: true, type: "text" }),
29
- react_1.default.createElement(kismaa_text_input_1.KismaaTextInput, { handleOnChange: handleOnChange, id: "email", placeholder: "Email", required: true, type: "email" })),
26
+ react_1.default.createElement(kismaa_text_input_1.KismaaTextInput, { handleOnChange: handleOnChange, id: "name", placeholder: "Name", required: true, type: "text", value: name }),
27
+ react_1.default.createElement(kismaa_text_input_1.KismaaTextInput, { handleOnChange: handleOnChange, id: "phone", placeholder: "Phone Number", required: true, type: "text", value: phone }),
28
+ react_1.default.createElement(kismaa_text_input_1.KismaaTextInput, { handleOnChange: handleOnChange, id: "subject", placeholder: "Subject", required: true, type: "text", value: subject }),
29
+ react_1.default.createElement(kismaa_text_input_1.KismaaTextInput, { handleOnChange: handleOnChange, id: "email", placeholder: "Email", required: true, type: "email", value: email })),
30
30
  react_1.default.createElement("div", { className: "mx-auto flex max-w-5xl flex-col gap-4" },
31
- react_1.default.createElement(kismaa_text_area_1.KismaaTextArea, { handleOnChange: handleOnChange, id: "comments", placeholder: "Comments...", required: true }),
31
+ react_1.default.createElement(kismaa_text_area_1.KismaaTextArea, { handleOnChange: handleOnChange, id: "comments", placeholder: "Comments...", required: true, value: comments }),
32
32
  react_1.default.createElement(molecules_1.Button, { type: molecules_1.BUTTON_TYPES.QUATERNARY, label: "Submit", handleOnClick: handleOnSubmit })))));
33
33
  };
34
34
  exports.ContactSection = ContactSection;
@@ -4,6 +4,7 @@ interface Props {
4
4
  id: string;
5
5
  placeholder: string;
6
6
  required?: boolean;
7
+ value: string;
7
8
  }
8
9
  export declare const KismaaTextArea: FC<Props>;
9
10
  export {};
@@ -6,9 +6,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.KismaaTextArea = void 0;
7
7
  var react_1 = __importDefault(require("react"));
8
8
  var KismaaTextArea = function (_a) {
9
- var handleOnChange = _a.handleOnChange, id = _a.id, placeholder = _a.placeholder, _b = _a.required, required = _b === void 0 ? false : _b;
9
+ var handleOnChange = _a.handleOnChange, id = _a.id, placeholder = _a.placeholder, _b = _a.required, required = _b === void 0 ? false : _b, value = _a.value;
10
10
  return (react_1.default.createElement("textarea", { className: "border-primary/70 mt-4 w-full rounded-md border p-4", id: id, onChange: function (e) {
11
11
  return handleOnChange(id, e.target.value);
12
- }, placeholder: placeholder, required: required, rows: 10 }));
12
+ }, placeholder: placeholder, required: required, rows: 10, value: value }));
13
13
  };
14
14
  exports.KismaaTextArea = KismaaTextArea;
@@ -5,6 +5,7 @@ interface Props {
5
5
  placeholder: string;
6
6
  required?: boolean;
7
7
  type: HTMLInputTypeAttribute;
8
+ value: string;
8
9
  }
9
10
  export declare const KismaaTextInput: FC<Props>;
10
11
  export {};
@@ -6,9 +6,9 @@ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.KismaaTextInput = void 0;
7
7
  var react_1 = __importDefault(require("react"));
8
8
  var KismaaTextInput = function (_a) {
9
- var handleOnChange = _a.handleOnChange, id = _a.id, placeholder = _a.placeholder, _b = _a.required, required = _b === void 0 ? false : _b, type = _a.type;
9
+ var handleOnChange = _a.handleOnChange, id = _a.id, placeholder = _a.placeholder, _b = _a.required, required = _b === void 0 ? false : _b, type = _a.type, value = _a.value;
10
10
  return (react_1.default.createElement("input", { className: "border-primary/70 rounded-md border p-4", id: id, onChange: function (e) {
11
11
  return handleOnChange(id, e.target.value);
12
- }, placeholder: placeholder, required: required, type: type }));
12
+ }, placeholder: placeholder, required: required, type: type, value: value }));
13
13
  };
14
14
  exports.KismaaTextInput = KismaaTextInput;
@@ -10,4 +10,9 @@ exports.contactSectionData = {
10
10
  description: "We're here for you—whenever you need guidance, support, or have questions about Kismaa. Whether you're facing a challenge, need help with the platform, or simply want to share your experience, don’t hesitate to reach out. Fill out the form below, and our team will get back to you as soon as possible.",
11
11
  handleOnSubmit: function () { return void 0; },
12
12
  handleOnChange: function () { return void 0; },
13
+ subject: '',
14
+ name: '',
15
+ comments: '',
16
+ phone: '',
17
+ email: '',
13
18
  };
@@ -1,9 +1,14 @@
1
1
  import { BreadcrumbsProps } from '../../molecules/breadcrumbs';
2
2
  export interface ContactSectionProps {
3
3
  breadcrumbs: BreadcrumbsProps;
4
+ comments: string;
4
5
  description: string;
6
+ email: string;
5
7
  handleOnChange: (k: string, v: string) => void;
6
8
  handleOnSubmit: () => void;
7
9
  heading: string;
10
+ name: string;
11
+ phone: string;
8
12
  subHeading: string;
13
+ subject: string;
9
14
  }
@@ -83,12 +83,12 @@ var Footer = function (_a) {
83
83
  react_1.default.createElement("div", { className: "text-neutral-800" },
84
84
  react_1.default.createElement(molecules_1.Typography, { variant: molecules_1.TYPOGRAPHY_VARIANTS.H5 }, "Quick Links")),
85
85
  react_1.default.createElement("div", { className: "mt-6 grid grid-cols-2 gap-14 text-neutral-800" },
86
- react_1.default.createElement("div", { className: "flex flex-col gap-4" }, quickLinksLeft.slice(0, 5).map(function (_a, index) {
86
+ react_1.default.createElement("div", { className: "flex flex-col gap-4" }, quickLinksLeft.slice(0, 6).map(function (_a, index) {
87
87
  var label = _a.label, href = _a.href;
88
88
  return (react_1.default.createElement(link_1.default, { key: index, href: href, className: "cursor-pointer" },
89
89
  react_1.default.createElement(molecules_1.Typography, { variant: molecules_1.TYPOGRAPHY_VARIANTS.SUBH4 }, label)));
90
90
  })),
91
- react_1.default.createElement("div", { className: "flex flex-col gap-4" }, quickLinksRight.slice(0, 5).map(function (_a, index) {
91
+ react_1.default.createElement("div", { className: "flex flex-col gap-4" }, quickLinksRight.slice(0, 6).map(function (_a, index) {
92
92
  var label = _a.label, href = _a.href;
93
93
  return (react_1.default.createElement(link_1.default, { key: index, href: href, className: "cursor-pointer" },
94
94
  react_1.default.createElement(molecules_1.Typography, { variant: molecules_1.TYPOGRAPHY_VARIANTS.SUBH4 }, label)));
@@ -56,28 +56,46 @@ exports.footerData = {
56
56
  order: 4,
57
57
  },
58
58
  {
59
- label: 'Blog',
60
- href: '/blog',
59
+ label: 'Contact',
60
+ href: '/contact',
61
61
  enabled: true,
62
62
  order: 5,
63
63
  },
64
64
  {
65
- label: 'Blog',
66
- href: '/blog',
65
+ label: 'Blog1',
66
+ href: '/blog1',
67
67
  enabled: true,
68
68
  order: 6,
69
69
  },
70
70
  {
71
- label: 'Blog',
72
- href: '/blog',
71
+ label: 'Blog2',
72
+ href: '/blog2',
73
73
  enabled: true,
74
74
  order: 7,
75
75
  },
76
76
  {
77
- label: 'Blog',
78
- href: '/blog',
77
+ label: 'Blog3',
78
+ href: '/blog3',
79
79
  enabled: true,
80
80
  order: 8,
81
81
  },
82
+ {
83
+ label: 'Blog4',
84
+ href: '/blog4',
85
+ enabled: true,
86
+ order: 9,
87
+ },
88
+ {
89
+ label: 'Blog5',
90
+ href: '/blog5',
91
+ enabled: true,
92
+ order: 10,
93
+ },
94
+ {
95
+ label: 'Blog6',
96
+ href: '/blog6',
97
+ enabled: true,
98
+ order: 11,
99
+ },
82
100
  ],
83
101
  };
@@ -14,7 +14,7 @@ var image_1 = __importDefault(require("next/image"));
14
14
  var mega_menu_1 = require("../mega-menu");
15
15
  var header_pointer_icon_1 = require("../../atoms/header-pointer-icon");
16
16
  var Navbar = function (_a) {
17
- var handleMegaMenuToggle = _a.handleMegaMenuToggle, handleSearch = _a.handleSearch, headerActions = _a.headerActions, isMobileMenuOpen = _a.isMobileMenuOpen, navLinks = _a.navLinks, toggleMobileMenu = _a.toggleMobileMenu;
17
+ var handleMegaMenuToggle = _a.handleMegaMenuToggle, handleSearch = _a.handleSearch, headerActions = _a.headerActions, isMobileMenuOpen = _a.isMobileMenuOpen, navLinks = _a.navLinks, _b = _a.showSearch, showSearch = _b === void 0 ? false : _b, toggleMobileMenu = _a.toggleMobileMenu;
18
18
  var renderNavLink = function (link) {
19
19
  var _a;
20
20
  return (react_1.default.createElement("div", { key: link.label, className: "relative w-fit", onMouseEnter: handleMegaMenuToggle, onMouseLeave: handleMegaMenuToggle },
@@ -41,8 +41,8 @@ var Navbar = function (_a) {
41
41
  .sort(function (a, b) { return a.order - b.order; })
42
42
  .map(function (link) { return renderNavLink(link); })),
43
43
  react_1.default.createElement("div", { className: "flex items-center justify-end gap-4" },
44
- react_1.default.createElement("div", { className: "", onClick: handleSearch },
45
- react_1.default.createElement(search_icon_1.SearchIcon, { className: "size-5 cursor-pointer" })),
44
+ showSearch && (react_1.default.createElement("div", { className: "", onClick: handleSearch },
45
+ react_1.default.createElement(search_icon_1.SearchIcon, { className: "size-5 cursor-pointer" }))),
46
46
  react_1.default.createElement("div", { className: "flex items-center justify-end" }, headerActions
47
47
  .filter(function (_a) {
48
48
  var enabled = _a.enabled;
@@ -17,10 +17,11 @@ export interface NavbarHeaderActionItem {
17
17
  type: BUTTON_TYPES;
18
18
  }
19
19
  export interface NavbarProps {
20
- headerActions: NavbarHeaderActionItem[];
21
20
  handleMegaMenuToggle: (e: MouseEvent<HTMLDivElement>) => void;
22
21
  handleSearch: () => void;
22
+ headerActions: NavbarHeaderActionItem[];
23
23
  isMobileMenuOpen: boolean;
24
24
  navLinks: NavLinks[];
25
+ showSearch?: boolean;
25
26
  toggleMobileMenu: () => void;
26
27
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@appcorp/kismaa-web-ui",
3
- "version": "0.2.15",
3
+ "version": "0.2.17",
4
4
  "source": "src/index.ts",
5
5
  "main": "lib/main.js",
6
6
  "module": "lib/module.js",