umwd-components 0.1.63 → 0.1.65

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.
@@ -13,10 +13,10 @@ var utils = require('../lib/utils.js');
13
13
  function StrapiImage(_ref) {
14
14
  let {
15
15
  src,
16
- alt,
17
- height,
18
- width,
19
- style
16
+ alt = "",
17
+ height = 500,
18
+ width = 500,
19
+ style = {}
20
20
  } = _ref;
21
21
  if (!src) return null;
22
22
  const imageUrl = utils.getStrapiMedia(src);
@@ -11,10 +11,10 @@ import { getStrapiMedia } from '../lib/utils.js';
11
11
  function StrapiImage(_ref) {
12
12
  let {
13
13
  src,
14
- alt,
15
- height,
16
- width,
17
- style
14
+ alt = "",
15
+ height = 500,
16
+ width = 500,
17
+ style = {}
18
18
  } = _ref;
19
19
  if (!src) return null;
20
20
  const imageUrl = getStrapiMedia(src);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "umwd-components",
3
- "version": "0.1.63",
3
+ "version": "0.1.65",
4
4
  "description": "UMWD Component library",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",
@@ -2,7 +2,7 @@
2
2
 
3
3
  import React from "react";
4
4
  import PropTypes from "prop-types";
5
- import TextImageBlock from "./TextImageSection.tsx";
5
+ import TextImageSection from "./TextImageSection.tsx";
6
6
  import { HeroSection } from "./HeroSection.tsx";
7
7
  import { FeatureSection } from "./FeaturesSection.tsx";
8
8
 
@@ -13,7 +13,7 @@ function blockRenderer(block) {
13
13
  case "layout.feature-section":
14
14
  return <FeatureSection key={block.id} data={block} />;
15
15
  case "layout.text-image-section":
16
- return <TextImageBlock key={block.id} data={block} />;
16
+ return <TextImageSection key={block.id} data={block} />;
17
17
  default:
18
18
  return null;
19
19
  }
@@ -12,10 +12,10 @@ interface StrapiImageProps {
12
12
 
13
13
  export function StrapiImage({
14
14
  src,
15
- alt,
16
- height,
17
- width,
18
- style,
15
+ alt = "",
16
+ height = 500,
17
+ width = 500,
18
+ style = {},
19
19
  }: Readonly<StrapiImageProps>) {
20
20
  if (!src) return null;
21
21
  const imageUrl = getStrapiMedia(src);
@@ -58,8 +58,6 @@ HelloWorld.args = {
58
58
  title: "Hello Mars",
59
59
  image: {
60
60
  url: "/uploads/man_in_circle_icon_6c77b6d3e4.png",
61
- width: 600,
62
- height: 600,
63
61
  alt: "Hello Mars",
64
62
  },
65
63
  text: "**Hello Mars,** \n a distant red planet that has captured the imagination of humanity for centuries. As we gaze upon your mysterious surface from Earth, we can't help but wonder about the secrets you hold. Hello to the vast landscapes of rust-colored terrain, the towering volcanoes, and the enigmatic canyons that weave across your surface. *Hello Mars,* a planet that has been the focus of numerous space missions, each one aiming to unveil the mysteries of your past and present. From the iconic rovers tirelessly traversing your rocky landscapes to the orbiters capturing breathtaking images from above, we extend our greetings to the scientific endeavors that seek to understand your geology, climate, and potential for life. <br /> <br /> *Hello Mars,* a beacon of human exploration and curiosity. The dreams of setting foot on your soil have fueled the aspirations of generations, and with each technological leap, the possibility of humans visiting you becomes more tangible. The prospect of a human settlement on Mars brings excitement, challenges, and the promise of a new chapter in our interplanetary journey. <br /> <br /> *Hello Mars,* a testament to the indomitable human spirit that constantly seeks to push the boundaries of what is possible. As we continue to study, explore, and dream about the mysteries you hold, we are reminded of the vastness of the cosmos and the endless opportunities for discovery that lie beyond our home planet.",