@rileybathurst/paddle 1.9.17 → 1.9.18

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@rileybathurst/paddle",
3
3
  "private": false,
4
- "version": "1.9.17",
4
+ "version": "1.9.18",
5
5
  "type": "module",
6
6
  "scripts": {
7
7
  "dev": "tsc --noEmit && stay-gold && vite",
@@ -9,10 +9,6 @@ export const PaddleLocationDeck = ({
9
9
  season_end,
10
10
  phone
11
11
  }: PaddleLocationDeckTypes) => {
12
-
13
- // TODO: testing
14
- console.log("PaddleLocationDeck phone", phone);
15
- console.log(typeof phone);
16
12
 
17
13
  return (
18
14
  <section className="location-deck">
@@ -181,12 +181,7 @@ export const PaddleLocation = ({
181
181
  season_start,
182
182
  season_end
183
183
  }: PaddleLocationTypes) => {
184
-
185
-
186
- // TODO: testing
187
- console.log("PaddleLocation phone", phone);
188
- console.log(typeof phone);
189
-
184
+
190
185
  const content = (
191
186
  <Content
192
187
  svg={svg}
@@ -5,11 +5,7 @@ import { PaddleInchesRemainder } from "./paddle-inches-remainder";
5
5
  import { PaddleTextureBackgrounds } from "./paddle-texture-backgrounds";
6
6
  import { PaddlePurchaseAndImageTypes } from "./types/paddle-purchase-image-types";
7
7
 
8
- // TODO: I'm not sure if this is needed or I can loop it easier
9
- interface NameTypes {
10
- name: string;
11
- }
12
- function Name({ name }: NameTypes) {
8
+ function Name({ name }: { name: string }) {
13
9
  return (
14
10
  <div className="badge">
15
11
  <h5 className="capitalize">{name}</h5>
package/src/phone.tsx CHANGED
@@ -6,14 +6,9 @@ interface FormatPhoneNumberTypes {
6
6
  const FormatPhoneNumber = ({ phone }: FormatPhoneNumberTypes) => {
7
7
  const phoneNumber = String(phone);
8
8
 
9
- // TODO: testing
10
- console.log("FormatPhoneNumber phone", phone);
11
9
  const cleaned = `${phoneNumber}`.replace(/\D/g, "");
12
10
  const match = cleaned.match(/^(\d{3})(\d{3})(\d{4})$/);
13
11
  if (match) {
14
-
15
- // TODO: testing
16
- console.log("match", match);
17
12
  return `(${match[1]}) ${match[2]}-${match[3]}`;
18
13
  }
19
14
  return null;
@@ -25,9 +20,6 @@ type PhoneTypes = {
25
20
 
26
21
  const Phone = ({ phone }: PhoneTypes) => {
27
22
 
28
- // TODO: testing
29
- console.log("phone", phone);
30
-
31
23
  return (
32
24
  <a href={`tel:${phone}`}
33
25
  rel="noopener noreferrer"
@@ -1,6 +1,6 @@
1
1
  import type { PaddleGatsbyImageType } from "./paddle-gatsby-image-type";
2
2
 
3
- type BasePaddlePurchaseTypes = {
3
+ export type PaddlePurchaseTypes = {
4
4
  id: React.Key;
5
5
  title: string;
6
6
  slug: string;
@@ -13,18 +13,17 @@ type BasePaddlePurchaseTypes = {
13
13
  discount?: number;
14
14
  cutout: PaddleGatsbyImageType;
15
15
 
16
+ sport: {
17
+ slug: string
18
+ };
19
+ brand: {
20
+ slug: string
21
+ };
22
+
16
23
  baseOne: { image: PaddleGatsbyImageType };
17
24
  baseTwo: { image: PaddleGatsbyImageType };
18
25
  baseThree: { image: PaddleGatsbyImageType };
19
26
  topOne: { image: PaddleGatsbyImageType };
20
27
  topTwo: { image: PaddleGatsbyImageType };
21
28
  topThree: { image: PaddleGatsbyImageType };
22
- };
23
-
24
- export type PaddlePurchaseTypes = BasePaddlePurchaseTypes & (
25
- | { sport: { slug: string }; sportSlug?: string }
26
- | { sportSlug: string; sport?: { slug: string } }
27
- ) & (
28
- | { brand: { slug: string }; brandSlug?: string }
29
- | { brandSlug: string; brand?: { slug: string } }
30
- );
29
+ };