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

@featherds/app-bar

Package Overview
Dependencies
Maintainers
2
Versions
74
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@featherds/app-bar - npm Package Compare versions

Comparing version 0.10.14 to 0.10.15

126

dist/app.es.js

@@ -23,6 +23,6 @@ var __defProp = Object.defineProperty;

import { FeatherRipple } from "@featherds/ripple";
import { defineComponent, ref, onMounted, resolveComponent, openBlock, createElementBlock, normalizeClass, createVNode, createBlock, createCommentVNode, toRef, inject, createElementVNode, toDisplayString, withModifiers, renderSlot } from "vue";
import { useScroll } from "@featherds/composables/events/Scroll";
import { defineComponent, ref, onMounted, resolveComponent, openBlock, createElementBlock, normalizeClass, createVNode, createBlock, createCommentVNode, toRef, inject, withCtx, createElementVNode, withModifiers, renderSlot } from "vue";
import Menu from "@featherds/icon/navigation/Menu";
var FeatherAppBarLink_vue_vue_type_style_index_0_scoped_true_lang = /* @__PURE__ */ (() => "a.round[data-v-95e5f316] {\n display: flex;\n align-items: center;\n height: 2.5rem;\n width: 2.5rem;\n border-radius: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n}\na.round[data-v-95e5f316]:hover {\n background: linear-gradient(rgba(var(--feather-state-color-on-color-r), var(--feather-state-color-on-color-g), var(--feather-state-color-on-color-b), var(--feather-state-opacity-hover-on-color)), rgba(var(--feather-state-color-on-color-r), var(--feather-state-color-on-color-g), var(--feather-state-color-on-color-b), var(--feather-state-opacity-hover-on-color)));\n}\na.round[data-v-95e5f316]:hover:focus {\n background: linear-gradient(rgba(var(--feather-state-color-on-color-r), var(--feather-state-color-on-color-g), var(--feather-state-color-on-color-b), var(--feather-state-opacity-hover-on-color)), rgba(var(--feather-state-color-on-color-r), var(--feather-state-color-on-color-g), var(--feather-state-color-on-color-b), var(--feather-state-opacity-hover-on-color))), linear-gradient(rgba(var(--feather-state-color-on-color-r), var(--feather-state-color-on-color-g), var(--feather-state-color-on-color-b), var(--feather-state-opacity-focus-on-color)), rgba(var(--feather-state-color-on-color-r), var(--feather-state-color-on-color-g), var(--feather-state-color-on-color-b), var(--feather-state-opacity-focus-on-color)));\n}\na.round[data-v-95e5f316]:focus {\n background: linear-gradient(rgba(var(--feather-state-color-on-color-r), var(--feather-state-color-on-color-g), var(--feather-state-color-on-color-b), var(--feather-state-opacity-focus-on-color)), rgba(var(--feather-state-color-on-color-r), var(--feather-state-color-on-color-g), var(--feather-state-color-on-color-b), var(--feather-state-opacity-focus-on-color)));\n border: 1px solid var(--feather-surface);\n outline: 0;\n}\na.round svg.feather-icon[data-v-95e5f316] {\n color: var(--feather-surface);\n height: 1.5rem;\n width: auto;\n}\na.round .ripple[data-v-95e5f316] {\n background-color: var(--feather-state-color-on-color);\n opacity: var(--feather-state-opacity-pressed-on-color);\n border-radius: 100%;\n}\na.round + a.round[data-v-95e5f316] {\n margin-left: var(--feather-spacing-xs);\n}\na.home[data-v-95e5f316] {\n height: auto;\n padding: 0.25rem;\n}\na.home[data-v-95e5f316]:focus {\n background: linear-gradient(rgba(var(--feather-state-color-on-color-r), var(--feather-state-color-on-color-g), var(--feather-state-color-on-color-b), var(--feather-state-opacity-focus-on-color)), rgba(var(--feather-state-color-on-color-r), var(--feather-state-color-on-color-g), var(--feather-state-color-on-color-b), var(--feather-state-opacity-focus-on-color)));\n}\na.home[data-v-95e5f316] svg.feather-icon {\n color: var(--feather-surface);\n height: 2rem;\n width: auto;\n}")();
import { ScrollHideHeader, SkipContentLink } from "@featherds/app-layout";
var FeatherAppBarLink_vue_vue_type_style_index_0_scoped_true_lang = /* @__PURE__ */ (() => "a.round[data-v-bd14578a] {\n color: var(--feather-state-text-color-on-surface-dark);\n border: 2px solid transparent;\n display: flex;\n align-items: center;\n height: 2.5rem;\n width: 2.5rem;\n border-radius: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n}\na.round[data-v-bd14578a]:visited {\n color: var(--feather-state-text-color-on-surface-dark);\n}\na.round .ripple[data-v-bd14578a] {\n background-color: var(--feather-state-color-on-surface-dark);\n opacity: var(--feather-state-opacity-pressed-on-surface-dark);\n}\na.round.selected[data-v-bd14578a],\na.round .selected[data-v-bd14578a] {\n background: var(--feather-state-background-selected-on-surface-dark);\n color: var(--feather-surface-dark);\n}\na.round.selected[data-v-bd14578a]:visited,\na.round .selected[data-v-bd14578a]:visited {\n color: var(--feather-surface-dark);\n}\na.round.hover[data-v-bd14578a]:hover, a.round:hover .hover[data-v-bd14578a] {\n background: linear-gradient(rgba(var(--feather-state-color-on-surface-dark-r), var(--feather-state-color-on-surface-dark-g), var(--feather-state-color-on-surface-dark-b), var(--feather-state-opacity-hover-on-surface-dark)), rgba(var(--feather-state-color-on-surface-dark-r), var(--feather-state-color-on-surface-dark-g), var(--feather-state-color-on-surface-dark-b), var(--feather-state-opacity-hover-on-surface-dark))), linear-gradient(var(--feather-surface-dark), var(--feather-surface-dark));\n color: var(--feather-state-text-color-hover-on-surface-dark);\n}\na.round.hover[data-v-bd14578a]:hover:visited, a.round:hover .hover[data-v-bd14578a]:visited {\n color: var(--feather-state-text-color-hover-on-surface-dark);\n}\na.round.hover:hover.selected[data-v-bd14578a], a.round:hover .hover.selected[data-v-bd14578a] {\n background: var(--feather-state-background-selected-on-surface-dark);\n color: var(--feather-surface-dark);\n}\na.round.hover:hover.selected[data-v-bd14578a]:visited, a.round:hover .hover.selected[data-v-bd14578a]:visited {\n color: var(--feather-surface-dark);\n}\na.round:focus.focus[data-v-bd14578a], a.round:focus .focus[data-v-bd14578a] {\n background: linear-gradient(rgba(var(--feather-state-color-on-surface-dark-r), var(--feather-state-color-on-surface-dark-g), var(--feather-state-color-on-surface-dark-b), var(--feather-state-opacity-focus-on-surface-dark)), rgba(var(--feather-state-color-on-surface-dark-r), var(--feather-state-color-on-surface-dark-g), var(--feather-state-color-on-surface-dark-b), var(--feather-state-opacity-focus-on-surface-dark))), linear-gradient(var(--feather-surface-dark), var(--feather-surface-dark));\n color: var(--feather-state-text-color-focus-on-surface-dark);\n border: var(--feather-state-border-focus-on-surface-dark);\n}\na.round:focus.focus[data-v-bd14578a]:visited, a.round:focus .focus[data-v-bd14578a]:visited {\n color: var(--feather-state-text-color-focus-on-surface-dark);\n}\na.round:focus.focus.selected[data-v-bd14578a], a.round:focus .focus.selected[data-v-bd14578a] {\n background: var(--feather-state-background-selected-on-surface-dark);\n color: var(--feather-surface-dark);\n}\na.round:focus.focus.selected[data-v-bd14578a]:visited, a.round:focus .focus.selected[data-v-bd14578a]:visited {\n color: var(--feather-surface-dark);\n}\na.round:hover:focus .focus.hover[data-v-bd14578a], a.round:hover:focus.focus.hover[data-v-bd14578a] {\n background: linear-gradient(rgba(var(--feather-state-color-on-surface-dark-r), var(--feather-state-color-on-surface-dark-g), var(--feather-state-color-on-surface-dark-b), var(--feather-state-opacity-hover-on-surface-dark)), rgba(var(--feather-state-color-on-surface-dark-r), var(--feather-state-color-on-surface-dark-g), var(--feather-state-color-on-surface-dark-b), var(--feather-state-opacity-hover-on-surface-dark))), linear-gradient(rgba(var(--feather-state-color-on-surface-dark-r), var(--feather-state-color-on-surface-dark-g), var(--feather-state-color-on-surface-dark-b), var(--feather-state-opacity-focus-on-surface-dark)), rgba(var(--feather-state-color-on-surface-dark-r), var(--feather-state-color-on-surface-dark-g), var(--feather-state-color-on-surface-dark-b), var(--feather-state-opacity-focus-on-surface-dark))), linear-gradient(var(--feather-surface-dark), var(--feather-surface-dark));\n color: var(--feather-state-text-color-focus-on-surface-dark);\n border: var(--feather-state-border-focus-on-surface-dark);\n}\na.round:hover:focus .focus.hover[data-v-bd14578a]:visited, a.round:hover:focus.focus.hover[data-v-bd14578a]:visited {\n color: var(--feather-state-text-color-focus-on-surface-dark);\n}\na.round:hover:focus .focus.hover.selected[data-v-bd14578a], a.round:hover:focus.focus.hover.selected[data-v-bd14578a] {\n background: var(--feather-state-background-selected-on-surface-dark);\n color: var(--feather-surface-dark);\n}\na.round:hover:focus .focus.hover.selected[data-v-bd14578a]:visited, a.round:hover:focus.focus.hover.selected[data-v-bd14578a]:visited {\n color: var(--feather-surface-dark);\n}\na.round svg.feather-icon[data-v-bd14578a] {\n height: 1.5rem;\n width: auto;\n}\na.round + a.round[data-v-bd14578a] {\n margin-left: var(--feather-spacing-xs);\n}\na.home[data-v-bd14578a] {\n height: auto;\n padding: 0.25rem;\n}\na.home[data-v-bd14578a]:focus {\n background: linear-gradient(rgba(var(--feather-state-color-on-color-r), var(--feather-state-color-on-color-g), var(--feather-state-color-on-color-b), var(--feather-state-opacity-focus-on-color)), rgba(var(--feather-state-color-on-color-r), var(--feather-state-color-on-color-g), var(--feather-state-color-on-color-b), var(--feather-state-opacity-focus-on-color)));\n}\na.home[data-v-bd14578a] svg.feather-icon {\n color: var(--feather-surface);\n height: 2rem;\n width: auto;\n}")();
var _export_sfc = (sfc, props2) => {

@@ -83,3 +83,3 @@ const target = sfc.__vccOpts || sfc;

"aria-label": _ctx.title,
class: normalizeClass(_ctx.type)
class: normalizeClass([_ctx.type, "hover focus"])
}, [

@@ -96,4 +96,4 @@ createVNode(_component_FeatherIcon, {

}
var FeatherAppBarLink = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render$1], ["__scopeId", "data-v-95e5f316"]]);
var FeatherAppBar_vue_vue_type_style_index_0_scoped_true_lang = /* @__PURE__ */ (() => ".center-horiz[data-v-7e69de0d] {\n display: flex;\n align-items: center;\n}\n.feather-app-bar-wrapper[data-v-7e69de0d],\n.banner[data-v-7e69de0d] {\n width: 100%;\n height: var(--feather-header-height);\n}\na.skip[data-v-7e69de0d] {\n box-shadow: var(--feather-shadow-2);\n background-color: var(--feather-elevation-background-2);\n font-family: var(--feather-header-font-family);\n color: var(--feather-primary-text-on-surface);\n text-rendering: optimizeLegibility;\n -webkit-font-smoothing: antialiased;\n -moz-osx-font-smoothing: grayscale;\n font-family: var(--feather-font-family);\n color: var(--feather-primary-text-on-surface);\n font-size: var(--feather-button-font-size);\n line-height: var(--feather-button-line-height);\n letter-spacing: var(--feather-button-letter-spacing);\n font-weight: var(--feather-button-font-weight);\n text-transform: var(--feather-button-text-transform);\n font-style: var(--feather-button-font-style);\n background-color: var(--feather-surface);\n padding: 0.25rem;\n position: absolute;\n top: 0px;\n left: 0px;\n border: 1px solid var(--feather-primary);\n}\na.skip[data-v-7e69de0d]:focus {\n z-index: var(--feather-zindex-tooltip);\n}\nheader[data-v-7e69de0d] {\n color: var(--feather-primary-text-on-color);\n box-shadow: var(--feather-shadow-4);\n background-color: var(--feather-elevation-background-4);\n position: fixed;\n top: 0;\n left: 0;\n z-index: var(--feather-zindex-fixed);\n background-color: var(--feather-secondary);\n transition: transform 280ms ease-in-out;\n}\nheader.show[data-v-7e69de0d] {\n transform: translateY(0px);\n}\nheader.hide[data-v-7e69de0d] {\n transform: translateY(-100%);\n}\nheader.no-transition[data-v-7e69de0d] {\n transition: none;\n}\n.header-content[data-v-7e69de0d] {\n margin: 0 auto;\n height: 100%;\n display: flex;\n justify-content: center;\n max-width: var(--feather-content-width);\n padding-top: 0;\n padding-bottom: 0;\n padding-left: 1.5rem;\n padding-right: 1.5rem;\n}\n@media (max-width: 66.5rem) {\n.header-content[data-v-7e69de0d] {\n padding-left: 1.5rem;\n padding-right: 1.5rem;\n}\n}\n.header-content .expand-button[data-v-7e69de0d] {\n display: none;\n}\n@media (max-width: 89.0625rem) {\n.header-content .expand-button[data-v-7e69de0d] {\n display: flex;\n}\n}\n.full-width .header-content[data-v-7e69de0d] {\n max-width: none;\n}\n.right[data-v-7e69de0d],\n.left[data-v-7e69de0d],\n.center[data-v-7e69de0d] {\n flex: 1;\n height: 100%;\n flex-shrink: 0;\n}\n.left *[data-v-7e69de0d]:first-child {\n margin-right: 0.625rem;\n}\n.right[data-v-7e69de0d] {\n justify-content: flex-end;\n margin-right: -0.5rem;\n padding-left: 0.5rem;\n}\n.center[data-v-7e69de0d] {\n flex: 0;\n}")();
var FeatherAppBarLink = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render$1], ["__scopeId", "data-v-bd14578a"]]);
var FeatherAppBar_vue_vue_type_style_index_0_scoped_true_lang = /* @__PURE__ */ (() => ".center-horiz[data-v-d414edfa] {\n display: flex;\n align-items: center;\n}\n.header[data-v-d414edfa] {\n color: var(--feather-state-text-color-on-surface-dark);\n box-shadow: var(--feather-shadow-4);\n background-color: var(--feather-elevation-background-4);\n position: fixed;\n top: 0;\n left: 0;\n z-index: var(--feather-zindex-fixed);\n background-color: var(--feather-surface-dark);\n border-bottom: 1px solid var(--feather-border-on-surface);\n width: 100%;\n height: var(--feather-header-height);\n}\n.header-content[data-v-d414edfa] {\n margin: 0 auto;\n height: 100%;\n display: flex;\n justify-content: center;\n max-width: var(--feather-content-width);\n padding-top: 0;\n padding-bottom: 0;\n padding-left: 1.5rem;\n padding-right: 1.5rem;\n}\n@media (max-width: 66.5rem) {\n.header-content[data-v-d414edfa] {\n padding-left: 1.5rem;\n padding-right: 1.5rem;\n}\n}\n.header-content .expand-button[data-v-d414edfa] {\n display: none;\n}\n@media (max-width: 89.0625rem) {\n.header-content .expand-button[data-v-d414edfa] {\n display: flex;\n}\n}\n.full-width.header-content[data-v-d414edfa] {\n max-width: none;\n}\n.right[data-v-d414edfa],\n.left[data-v-d414edfa],\n.center[data-v-d414edfa] {\n flex: 1;\n height: 100%;\n flex-shrink: 0;\n}\n.left *[data-v-d414edfa]:first-child {\n margin-right: 0.625rem;\n}\n.right[data-v-d414edfa] {\n justify-content: flex-end;\n margin-right: -0.5rem;\n padding-left: 0.5rem;\n}\n.center[data-v-d414edfa] {\n flex: 0;\n}")();
const LABELS = {

@@ -134,28 +134,2 @@ skip: "REQUIRED",

const wrapper = ref();
if (props2.scrollHide) {
let previousScrollPosition = 0;
let height = 60;
const onScroll = () => {
height = parseInt(getComputedStyle(wrapper.value).getPropertyValue("--feather-header-height"), 10);
const scrollTop = document.documentElement.scrollTop;
const scrollingDown = scrollTop >= previousScrollPosition;
previousScrollPosition = scrollTop;
if (scrollTop > height && scrollingDown) {
displayClass.value = "hide";
return;
}
if (scrollTop > height && !scrollingDown) {
displayClass.value = "show";
return;
}
displayClass.value = "show";
};
onMounted(() => {
const documentRef = ref(document);
const activate = useScroll(documentRef, onScroll);
activate.value = true;
onScroll();
transitionClass.value = "";
});
}
const useExpander = () => {

@@ -167,3 +141,4 @@ const expander = inject("feather-app-layout-expander", false);

}
return { canShowExpand: ref(false) };
return { canShowExpand: ref(false), expand: () => {
} };
};

@@ -179,5 +154,2 @@ return __spreadValues(__spreadProps(__spreadValues({

computed: {
contentId() {
return `#${this.content}`;
},
menu() {

@@ -188,46 +160,54 @@ return Menu;

components: {
ScrollHideHeader,
SkipContentLink,
FeatherAppBarLink
}
});
const _hoisted_1 = ["href"];
const _hoisted_2 = { class: "header-content center-horiz" };
const _hoisted_3 = { class: "left center-horiz" };
const _hoisted_4 = { class: "center center-horiz" };
const _hoisted_5 = { class: "right center-horiz" };
const _hoisted_1 = { class: "header" };
const _hoisted_2 = { class: "left center-horiz" };
const _hoisted_3 = { class: "center center-horiz" };
const _hoisted_4 = { class: "right center-horiz" };
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
const _component_SkipContentLink = resolveComponent("SkipContentLink");
const _component_FeatherAppBarLink = resolveComponent("FeatherAppBarLink");
return openBlock(), createElementBlock("div", {
class: normalizeClass(["feather-app-bar-wrapper", { "full-width": !!_ctx.full }]),
ref: "wrapper"
}, [
createElementVNode("a", {
class: "skip",
href: _ctx.contentId
}, toDisplayString(_ctx.skipLabel), 9, _hoisted_1),
createElementVNode("header", {
class: normalizeClass(["banner", [_ctx.displayClass, _ctx.transitionClass]])
}, [
createElementVNode("div", _hoisted_2, [
createElementVNode("div", _hoisted_3, [
_ctx.canShowExpand ? (openBlock(), createBlock(_component_FeatherAppBarLink, {
key: 0,
class: "expand-button",
icon: _ctx.menu,
title: _ctx.expandLabel,
onClick: withModifiers(_ctx.expand, ["stop", "prevent"]),
url: "#"
}, null, 8, ["icon", "title", "onClick"])) : createCommentVNode("", true),
renderSlot(_ctx.$slots, "left", {}, void 0, true)
]),
createElementVNode("div", _hoisted_4, [
renderSlot(_ctx.$slots, "center", {}, void 0, true)
]),
createElementVNode("div", _hoisted_5, [
renderSlot(_ctx.$slots, "right", {}, void 0, true)
])
const _component_ScrollHideHeader = resolveComponent("ScrollHideHeader");
return openBlock(), createBlock(_component_ScrollHideHeader, {
class: "feather-app-bar-wrapper",
"scroll-hide": _ctx.scrollHide
}, {
pre: withCtx(() => [
createVNode(_component_SkipContentLink, {
content: _ctx.content,
"skip-label": _ctx.skipLabel
}, null, 8, ["content", "skip-label"])
]),
default: withCtx(() => [
createElementVNode("div", _hoisted_1, [
createElementVNode("div", {
class: normalizeClass(["header-content center-horiz", { "full-width": !!_ctx.full }])
}, [
createElementVNode("div", _hoisted_2, [
_ctx.canShowExpand ? (openBlock(), createBlock(_component_FeatherAppBarLink, {
key: 0,
class: "expand-button",
icon: _ctx.menu,
title: _ctx.expandLabel,
onClick: withModifiers(_ctx.expand, ["stop", "prevent"]),
url: "#"
}, null, 8, ["icon", "title", "onClick"])) : createCommentVNode("", true),
renderSlot(_ctx.$slots, "left", {}, void 0, true)
]),
createElementVNode("div", _hoisted_3, [
renderSlot(_ctx.$slots, "center", {}, void 0, true)
]),
createElementVNode("div", _hoisted_4, [
renderSlot(_ctx.$slots, "right", {}, void 0, true)
])
], 2)
])
], 2)
], 2);
]),
_: 3
}, 8, ["scroll-hide"]);
}
var FeatherAppBar = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-7e69de0d"]]);
var FeatherAppBar = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-d414edfa"]]);
export { FeatherAppBar, FeatherAppBarLink };
{
"name": "@featherds/app-bar",
"version": "0.10.14",
"version": "0.10.15",
"publishConfig": {

@@ -12,6 +12,8 @@ "access": "public"

"dependencies": {
"@featherds/composables": "^0.10.14",
"@featherds/icon": "^0.10.14",
"@featherds/ripple": "^0.10.14",
"@featherds/styles": "^0.10.14",
"@featherds/app-layout": "^0.10.15",
"@featherds/composables": "^0.10.15",
"@featherds/icon": "^0.10.15",
"@featherds/list": "^0.10.15",
"@featherds/ripple": "^0.10.15",
"@featherds/styles": "^0.10.15",
"vue": "^3.1.0-0"

@@ -24,3 +26,3 @@ },

"types": "./src/index.d.ts",
"gitHead": "b85d6ce9dee5d75ce5f6b58b73c34d2c8439b8dd"
"gitHead": "dda92cf914287cfa8899add188f45e5e778eca9b"
}

@@ -1,10 +0,7 @@

declare module "@featherds/app-bar" {
import { DefineComponent } from "vue";
const FeatherAppBar: DefineComponent<
typeof import("./components/FeatherAppBar.vue").props
>;
const FeatherAppBarLink: DefineComponent<
typeof import("./components/FeatherAppBarLink.vue").props
>;
export { FeatherAppBar, FeatherAppBarLink };
}
import { DefineComponent } from "vue";
export const FeatherAppBar: DefineComponent<
typeof import("./components/FeatherAppBar.vue").props
>;
export const FeatherAppBarLink: DefineComponent<
typeof import("./components/FeatherAppBarLink.vue").props
>;

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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