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

@hashicorp/hashi-callouts

Package Overview
Dependencies
Maintainers
8
Versions
34
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@hashicorp/hashi-callouts - npm Package Compare versions

Comparing version 0.0.8 to 1.0.0

72

dist/index.js

@@ -9,31 +9,55 @@ 'use strict';

function Callouts(_ref) {
var _state = _ref._state,
_data = _ref._data;
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
var data = reshapePreactComponents.decode(_data);
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
return preact.h(
'ul',
{ 'class': 'g-callouts' + (data.two_columns ? ' two-columns' : '') },
data.items.map(function (item) {
function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; }
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }
var Callouts = function (_Component) {
_inherits(Callouts, _Component);
function Callouts() {
_classCallCheck(this, Callouts);
return _possibleConstructorReturn(this, (Callouts.__proto__ || Object.getPrototypeOf(Callouts)).apply(this, arguments));
}
_createClass(Callouts, [{
key: 'render',
value: function render() {
var data = reshapePreactComponents.decode(this.props._data);
return preact.h(
'li',
null,
item.image && preact.h(
'div',
{ 'class': 'callout-icon' },
preact.h('img', { src: item.image.url, alt: item.image.alt })
),
preact.h(
'h5',
null,
item.title
),
item.description && marked.inlineLexer(item.description, [])
'ul',
{ 'class': 'g-callouts' + (data.two_columns ? ' two-columns' : '') },
data.items.map(function (item) {
return preact.h(
'li',
null,
item.image && preact.h(
'div',
{ 'class': 'callout-icon' },
preact.h('img', { src: item.image.url, alt: item.image.alt })
),
preact.h(
'h5',
null,
item.title
),
preact.h('span', {
dangerouslySetInnerHTML: {
__html: item.description ? marked.inlineLexer(item.description, []) : ''
}
})
);
})
);
})
);
}
}
}]);
return Callouts;
}(preact.Component);
module.exports = Callouts;
{
"name": "@hashicorp/hashi-callouts",
"description": "a set of three horizontally-aligned images paired with a short title and descriptive text.",
"version": "0.0.8",
"version": "1.0.0",
"author": "Hashicorp - Jeff Escalante",
"main": "dist",
"peerDependencies": {
"8fold-marked": "^0.3.8",
"preact": "^8.2.6",
"reshape-preact-components": "^0.6.0"
"8fold-marked": "~0.3.8",
"preact": "^8.2.7",
"reshape-preact-components": "~0.6.0"
},

@@ -11,0 +12,0 @@ "publishConfig": {

Sorry, the diff of this file is not supported yet

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