math-main-components 0.0.159 → 0.0.160

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/dist/index.cjs.js CHANGED
@@ -256,25 +256,25 @@ var styles$h = {"container":"styles-module_container__IXTeq","input":"styles-mod
256
256
  styleInject(css_248z$h);
257
257
 
258
258
  function InputNames({ width = "100%", placeholder = { firstName: "", lastName: "" }, title = { firstName: "Vorname", lastName: "Nachname" }, defaultValue = { firstName: "", lastName: "" }, onInput = (name, event) => { }, onInputFirstName = (event) => { }, onInputLastName = (event) => { }, }) {
259
- const [value1, setValue1] = React.useState(defaultValue.firstName ? defaultValue.firstName : "");
260
- const [value2, setValue2] = React.useState(defaultValue.lastName ? defaultValue.lastName : "");
259
+ const [firstName, setFirstName] = React.useState(defaultValue.firstName ? defaultValue.firstName : "");
260
+ const [lastName, setLastName] = React.useState(defaultValue.lastName ? defaultValue.lastName : "");
261
261
  function onInput1(event) {
262
- setValue1(event.target.value);
262
+ setFirstName(event.target.value);
263
263
  onInputFirstName(event);
264
264
  onInput("firstName", event);
265
265
  }
266
266
  function onInput2(event) {
267
- setValue2(event.target.value);
267
+ setLastName(event.target.value);
268
268
  onInputLastName(event);
269
269
  onInput("lastName", event);
270
270
  }
271
271
  return (React__default["default"].createElement("div", { className: styles$h.container, style: { width: width } },
272
272
  React__default["default"].createElement("div", { className: styles$h.form },
273
- React__default["default"].createElement("input", { className: `${styles$h.input} ${title.firstName != undefined ? styles$h.with_title : styles$h.without_title} ${value1.length > 0 ? styles$h.valid : styles$h.not_valid}`, name: "firstName", type: "name", style: { width: width != "100%" ? "100px" : width }, placeholder: placeholder.firstName, defaultValue: defaultValue.firstName, onInput: onInput1 }),
273
+ React__default["default"].createElement("input", { className: `${styles$h.input} ${title.firstName != undefined ? styles$h.with_title : styles$h.without_title} ${firstName.length > 0 ? styles$h.valid : styles$h.not_valid}`, name: "firstName", type: "name", style: { width: width != "100%" ? "100px" : width }, placeholder: placeholder.firstName, defaultValue: defaultValue.firstName, onInput: onInput1 }),
274
274
  React__default["default"].createElement("label", { htmlFor: "text", className: styles$h.label },
275
275
  React__default["default"].createElement("span", { className: styles$h.label_text }, title.firstName))),
276
276
  React__default["default"].createElement("div", { className: styles$h.form },
277
- React__default["default"].createElement("input", { className: `${styles$h.input} ${title.lastName != undefined ? styles$h.with_title : styles$h.without_title} ${value2.length > 0 ? styles$h.valid : styles$h.not_valid}`, name: "lastName", type: "name", style: { width: width != "100%" ? "100px" : width }, placeholder: placeholder.lastName, defaultValue: defaultValue.lastName, onInput: onInput2 }),
277
+ React__default["default"].createElement("input", { className: `${styles$h.input} ${title.lastName != undefined ? styles$h.with_title : styles$h.without_title} ${lastName.length > 0 ? styles$h.valid : styles$h.not_valid}`, name: "lastName", type: "name", style: { width: width != "100%" ? "100px" : width }, placeholder: placeholder.lastName, defaultValue: defaultValue.lastName, onInput: onInput2 }),
278
278
  React__default["default"].createElement("label", { htmlFor: "text", className: styles$h.label },
279
279
  React__default["default"].createElement("span", { className: styles$h.label_text }, title.lastName)))));
280
280
  }
package/dist/index.esm.js CHANGED
@@ -248,25 +248,25 @@ var styles$h = {"container":"styles-module_container__IXTeq","input":"styles-mod
248
248
  styleInject(css_248z$h);
249
249
 
250
250
  function InputNames({ width = "100%", placeholder = { firstName: "", lastName: "" }, title = { firstName: "Vorname", lastName: "Nachname" }, defaultValue = { firstName: "", lastName: "" }, onInput = (name, event) => { }, onInputFirstName = (event) => { }, onInputLastName = (event) => { }, }) {
251
- const [value1, setValue1] = useState(defaultValue.firstName ? defaultValue.firstName : "");
252
- const [value2, setValue2] = useState(defaultValue.lastName ? defaultValue.lastName : "");
251
+ const [firstName, setFirstName] = useState(defaultValue.firstName ? defaultValue.firstName : "");
252
+ const [lastName, setLastName] = useState(defaultValue.lastName ? defaultValue.lastName : "");
253
253
  function onInput1(event) {
254
- setValue1(event.target.value);
254
+ setFirstName(event.target.value);
255
255
  onInputFirstName(event);
256
256
  onInput("firstName", event);
257
257
  }
258
258
  function onInput2(event) {
259
- setValue2(event.target.value);
259
+ setLastName(event.target.value);
260
260
  onInputLastName(event);
261
261
  onInput("lastName", event);
262
262
  }
263
263
  return (React.createElement("div", { className: styles$h.container, style: { width: width } },
264
264
  React.createElement("div", { className: styles$h.form },
265
- React.createElement("input", { className: `${styles$h.input} ${title.firstName != undefined ? styles$h.with_title : styles$h.without_title} ${value1.length > 0 ? styles$h.valid : styles$h.not_valid}`, name: "firstName", type: "name", style: { width: width != "100%" ? "100px" : width }, placeholder: placeholder.firstName, defaultValue: defaultValue.firstName, onInput: onInput1 }),
265
+ React.createElement("input", { className: `${styles$h.input} ${title.firstName != undefined ? styles$h.with_title : styles$h.without_title} ${firstName.length > 0 ? styles$h.valid : styles$h.not_valid}`, name: "firstName", type: "name", style: { width: width != "100%" ? "100px" : width }, placeholder: placeholder.firstName, defaultValue: defaultValue.firstName, onInput: onInput1 }),
266
266
  React.createElement("label", { htmlFor: "text", className: styles$h.label },
267
267
  React.createElement("span", { className: styles$h.label_text }, title.firstName))),
268
268
  React.createElement("div", { className: styles$h.form },
269
- React.createElement("input", { className: `${styles$h.input} ${title.lastName != undefined ? styles$h.with_title : styles$h.without_title} ${value2.length > 0 ? styles$h.valid : styles$h.not_valid}`, name: "lastName", type: "name", style: { width: width != "100%" ? "100px" : width }, placeholder: placeholder.lastName, defaultValue: defaultValue.lastName, onInput: onInput2 }),
269
+ React.createElement("input", { className: `${styles$h.input} ${title.lastName != undefined ? styles$h.with_title : styles$h.without_title} ${lastName.length > 0 ? styles$h.valid : styles$h.not_valid}`, name: "lastName", type: "name", style: { width: width != "100%" ? "100px" : width }, placeholder: placeholder.lastName, defaultValue: defaultValue.lastName, onInput: onInput2 }),
270
270
  React.createElement("label", { htmlFor: "text", className: styles$h.label },
271
271
  React.createElement("span", { className: styles$h.label_text }, title.lastName)))));
272
272
  }
@@ -2,6 +2,7 @@ import { PortableTextBlock } from "sanity";
2
2
  import { Category } from "./Category";
3
3
  export type Calculator = {
4
4
  _id: string;
5
+ _type: "calculators";
5
6
  previewImage: {
6
7
  asset: {
7
8
  _ref: string;
@@ -1,5 +1,6 @@
1
1
  export type Category = {
2
2
  _id: string;
3
+ _type: "categories";
3
4
  title: string;
4
5
  isTopLevel: boolean;
5
6
  hasEBooks: boolean;
@@ -3,6 +3,7 @@ import { Category } from "./Category";
3
3
  import { Product } from "./Product";
4
4
  export type Ebook = {
5
5
  _id: string;
6
+ _type: "ebooks";
6
7
  title: string;
7
8
  previewImage: {
8
9
  asset: {
@@ -1,5 +1,6 @@
1
1
  export type HelpData = {
2
2
  _id: string;
3
+ _type: "helpData";
3
4
  title: string;
4
5
  content: any;
5
6
  openButtonText: string;
@@ -1,6 +1,7 @@
1
1
  import { Category } from "./Category";
2
2
  export type Material = {
3
3
  _id: string;
4
+ _type: "materials";
4
5
  title: string;
5
6
  fileId: string;
6
7
  fileExpire?: string;
@@ -2,6 +2,7 @@ import { PortableTextBlock } from "sanity";
2
2
  import { Category } from "./Category";
3
3
  export type Movie = {
4
4
  _id: string;
5
+ _type: "movies";
5
6
  title: string;
6
7
  previewImage: {
7
8
  asset: {
@@ -2,6 +2,7 @@ import { PortableTextBlock } from "sanity";
2
2
  import { Ebook } from "./Ebook";
3
3
  export type Product = {
4
4
  _id: string;
5
+ _type: "product";
5
6
  title: string;
6
7
  combinable: boolean;
7
8
  enabled: boolean;
@@ -1,11 +1,14 @@
1
1
  import { PortableTextBlock } from "sanity";
2
2
  export type About = {
3
- id: number;
3
+ _id: string;
4
+ _type: "about";
4
5
  quote: string;
5
6
  description: PortableTextBlock[];
6
7
  persons: Person[];
7
8
  };
8
9
  export type Person = {
10
+ _id: number;
11
+ _type: "person";
9
12
  name: string;
10
13
  role: string;
11
14
  linkedIn: string;
@@ -1,5 +1,6 @@
1
1
  export type BenefitForIndividuals = {
2
2
  _id: string;
3
+ _type: "benefitsForIndividual";
3
4
  priority: number;
4
5
  title: string;
5
6
  subtitle: string;
@@ -1,5 +1,6 @@
1
1
  export type BenefitForSchools = {
2
2
  _id: string;
3
+ _type: "benefitsForSchools";
3
4
  priority: number;
4
5
  title: string;
5
6
  subtitle: string;
@@ -1,5 +1,6 @@
1
1
  export type Concept = {
2
2
  _id: string;
3
+ _type: "concept";
3
4
  title: string;
4
5
  subtitle: string;
5
6
  description: string;
@@ -1,6 +1,7 @@
1
1
  import { PortableTextBlock } from "sanity";
2
2
  export type Content = {
3
3
  _id: string;
4
+ _type: "content";
4
5
  priority: number;
5
6
  title: string;
6
7
  subtitle: string;
@@ -1,6 +1,7 @@
1
1
  import { PortableTextBlock } from "sanity";
2
2
  export type Faq = {
3
3
  _id: string;
4
+ _type: "faq";
4
5
  priority: number;
5
6
  question: string;
6
7
  answer: PortableTextBlock[];
@@ -1,5 +1,6 @@
1
1
  export type Feature = {
2
2
  _id: string;
3
+ _type: "feature";
3
4
  priority: number;
4
5
  title: string;
5
6
  subtitle: string;
@@ -1,5 +1,6 @@
1
1
  export type FooterLink = {
2
2
  _id: string;
3
+ _type: "footerLinks";
3
4
  title: string;
4
5
  link: string;
5
6
  priority: number;
@@ -1,7 +1,7 @@
1
1
  import { PortableTextBlock } from "sanity";
2
2
  export type Home = {
3
3
  _id: string;
4
- _type: string;
4
+ _type: "home";
5
5
  helpMockup?: {
6
6
  asset: {
7
7
  _type: string;
@@ -1,6 +1,7 @@
1
1
  import { PortableTextBlock } from "sanity";
2
2
  export type News = {
3
3
  _id: string;
4
+ _type: "news";
4
5
  visible: boolean;
5
6
  headline: string;
6
7
  slug: {
@@ -2,6 +2,7 @@ import { PortableTextBlock } from "sanity";
2
2
  import { Product } from "../Product";
3
3
  export type Pricing = {
4
4
  _id: string;
5
+ _type: "pricing";
5
6
  title: string;
6
7
  position: PricingPosition;
7
8
  limitation: string;
@@ -1,5 +1,7 @@
1
1
  import { PortableTextBlock } from "sanity";
2
2
  export type StaticPage = {
3
+ _id: string;
4
+ _type: "page";
3
5
  title: string;
4
6
  slug: {
5
7
  current: string;
@@ -1,5 +1,6 @@
1
1
  export type Website = {
2
2
  _id: string;
3
+ _type: "website";
3
4
  heroDescription: string;
4
5
  heroTitle: string;
5
6
  title: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "math-main-components",
3
- "version": "0.0.159",
3
+ "version": "0.0.160",
4
4
  "author": "Emilian Scheel",
5
5
  "files": [
6
6
  "dist/**/*"