Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@ausbom/card

Package Overview
Dependencies
Maintainers
5
Versions
64
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ausbom/card - npm Package Compare versions

Comparing version 0.4.3 to 0.4.4

14

CHANGELOG.md

@@ -6,2 +6,16 @@ # Change Log

<a name="0.4.4"></a>
## [0.4.4](https://github.com/AusBOM/bom-design-system/compare/@ausbom/card@0.4.3...@ausbom/card@0.4.4) (2020-03-13)
### Bug Fixes
* a11y [#38](https://github.com/AusBOM/bom-design-system/issues/38) removes unneccasary alt text from cards ([5a5f115](https://github.com/AusBOM/bom-design-system/commit/5a5f115))
* a11y [#39](https://github.com/AusBOM/bom-design-system/issues/39) adds role=text to media cards as recommended by intopia ([ad34731](https://github.com/AusBOM/bom-design-system/commit/ad34731))
* a11y [#40](https://github.com/AusBOM/bom-design-system/issues/40) remove list markup for media card meta items ([b6865bd](https://github.com/AusBOM/bom-design-system/commit/b6865bd))
<a name="0.4.3"></a>

@@ -8,0 +22,0 @@ ## [0.4.3](https://github.com/AusBOM/bom-design-system/compare/@ausbom/card@0.4.2...@ausbom/card@0.4.3) (2020-03-13)

2

lib/components/MediaCard/MediaCard.js
"use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports["default"]=void 0;var _extends2=_interopRequireDefault(require("@babel/runtime/helpers/extends"));var _objectWithoutProperties2=_interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));var _classCallCheck2=_interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));var _createClass2=_interopRequireDefault(require("@babel/runtime/helpers/createClass"));var _possibleConstructorReturn2=_interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));var _getPrototypeOf2=_interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));var _inherits2=_interopRequireDefault(require("@babel/runtime/helpers/inherits"));var _defineProperty2=_interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));var _classnames=_interopRequireDefault(require("classnames"));var _react=_interopRequireDefault(require("react"));var MediaCard=/*#__PURE__*/function(_React$PureComponent){(0,_inherits2["default"])(MediaCard,_React$PureComponent);function MediaCard(){(0,_classCallCheck2["default"])(this,MediaCard);return(0,_possibleConstructorReturn2["default"])(this,(0,_getPrototypeOf2["default"])(MediaCard).apply(this,arguments))}(0,_createClass2["default"])(MediaCard,[{key:"render",value:function render(){var _ref=this.props,Tag=_ref.as,className=_ref.className,id=_ref.id,image=_ref.image,title=_ref.title,TitleTag=_ref.titleTag,horizontal=_ref.horizontal,meta=_ref.meta,innerRef=_ref.innerRef,children=_ref.children,restProps=(0,_objectWithoutProperties2["default"])(_ref,["as","className","id","image","title","titleTag","horizontal","meta","innerRef","children"]);// eslint-disable-line no-empty-pattern
var classes=(0,_classnames["default"])(className,"bom-media-card",{"bom-media-card--stacked":!horizontal,"bom-media-card--with-image":!!image});var metaItems=_react["default"].Children.map(meta,function(data){return _react["default"].createElement("li",{className:"bom-media-card-meta__item"},data)});return _react["default"].createElement(Tag,(0,_extends2["default"])({className:classes,"aria-describedby":meta?id:undefined,ref:innerRef},restProps),image&&_react["default"].createElement("div",{className:"bom-media-card__img"},image),_react["default"].createElement("div",{className:"bom-media-card__text"},_react["default"].createElement(TitleTag,{className:"bom-media-card__title"},title),metaItems&&metaItems.length&&_react["default"].createElement("ul",{className:"bom-media-card-meta"},metaItems),children&&_react["default"].createElement("div",{id:id,className:"bom-media-card__desc"},children)))}}]);return MediaCard}(_react["default"].PureComponent);(0,_defineProperty2["default"])(MediaCard,"defaultProps",{as:"a",titleTag:"h3",horizontal:false});var MediaCardWithRef=_react["default"].forwardRef(function(props,ref){return _react["default"].createElement(MediaCard,(0,_extends2["default"])({innerRef:ref},props))});MediaCardWithRef.displayName="MediaCard";var _default=MediaCardWithRef;exports["default"]=_default;
var classes=(0,_classnames["default"])(className,"bom-media-card",{"bom-media-card--stacked":!horizontal,"bom-media-card--with-image":!!image});var metaItems=_react["default"].Children.map(meta,function(data){return _react["default"].createElement("div",{className:"bom-media-card-meta__item"},data)});return _react["default"].createElement(Tag,(0,_extends2["default"])({className:classes,"aria-describedby":meta?id:undefined,ref:innerRef},restProps),image&&_react["default"].createElement("div",{className:"bom-media-card__img"},image),_react["default"].createElement("div",{role:"text",className:"bom-media-card__text"},_react["default"].createElement(TitleTag,{className:"bom-media-card__title"},title),metaItems&&metaItems.length&&_react["default"].createElement("div",{className:"bom-media-card-meta"},metaItems),children&&_react["default"].createElement("div",{id:id,className:"bom-media-card__desc"},children)))}}]);return MediaCard}(_react["default"].PureComponent);(0,_defineProperty2["default"])(MediaCard,"defaultProps",{as:"a",titleTag:"h3",horizontal:false});var MediaCardWithRef=_react["default"].forwardRef(function(props,ref){return _react["default"].createElement(MediaCard,(0,_extends2["default"])({innerRef:ref},props))});MediaCardWithRef.displayName="MediaCard";var _default=MediaCardWithRef;exports["default"]=_default;
{
"name": "@ausbom/card",
"version": "0.4.3",
"version": "0.4.4",
"description": "",

@@ -42,7 +42,7 @@ "keywords": [],

"@ausbom/grid": "^0.4.2",
"@ausbom/icon": "^0.8.1",
"@ausbom/icon": "^0.8.2",
"@ausbom/styles": "^0.8.0",
"@ausbom/typography": "^0.3.2"
},
"gitHead": "cd14fef5a1fcdc0716095b2045d0b230e71d9d8c"
"gitHead": "59a1c1a3b82f7dfeb7215b4b21408e1d15b1862a"
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc