Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • adi-ia/enrollment-profile
  • SABERG3/enrollment-profile
2 results
Show changes
Commits on Source (13)
# myuw-profile versions # myuw-profile versions
## 1.3.2
### Fixed
* Check for valid references before messing with DOM elements/variables
## 1.3.0 ## 1.3.0
### Added ### Added
......
...@@ -9,7 +9,7 @@ Add the following import to your page's `<head>`: ...@@ -9,7 +9,7 @@ Add the following import to your page's `<head>`:
<script nomodule src="https://unpkg.com/@myuw-web-components/myuw-profile@^1"></script> <script nomodule src="https://unpkg.com/@myuw-web-components/myuw-profile@^1"></script>
``` ```
*Note: You may want to specify a specific version of the component to ensure stability. See [the change log](CHANGELOG.md) or the [npm entry](https://www.npmjs.com/package/@myuw-web-components/myuw-profile) for version information. *Note: You may want to specify a specific version of the component to ensure stability. See [the change log](CHANGELOG.md) or the [npm entry](https://www.npmjs.com/package/@myuw-web-components/myuw-profile) for version information.*
Use the component's HTML tag wherever you want: Use the component's HTML tag wherever you want:
...@@ -80,3 +80,7 @@ document.addEventListener('WebComponentsReady', function() { ...@@ -80,3 +80,7 @@ document.addEventListener('WebComponentsReady', function() {
- `--myuw-menu-color`: The text color of links/buttons in the profile menu - `--myuw-menu-color`: The text color of links/buttons in the profile menu
For more information about CSS variables and how they work with MyUW Web Components, [reference the styles component](https://github.com/myuw-web-components/myuw-app-styles "reference the styles component") For more information about CSS variables and how they work with MyUW Web Components, [reference the styles component](https://github.com/myuw-web-components/myuw-app-styles "reference the styles component")
Cross-browser testing provided by:<br/>
<a href="https://www.browserstack.com/"><img width="160" src="https://myuw-web-components.github.io/img/Browserstack-logo.svg" alt="BrowserStack"/></a>
...@@ -49,6 +49,10 @@ ...@@ -49,6 +49,10 @@
} }
</style> </style>
<script src="https://unpkg.com/css-vars-ponyfill@1"></script>
<script>
cssVars({shadowDOM: true,watch: true});
</script>
<!-- Web component polyfill loader --> <!-- Web component polyfill loader -->
<script src="https://unpkg.com/@webcomponents/webcomponentsjs@2.1.3/webcomponents-loader.js"></script> <script src="https://unpkg.com/@webcomponents/webcomponentsjs@2.1.3/webcomponents-loader.js"></script>
......
This diff is collapsed.
{ {
"name": "@myuw-web-components/myuw-profile", "name": "enrollment-profile",
"version": "1.3.0", "version": "1.3.1",
"description": "Web component that provides an avatar button and profile menu", "description": "Web component that provides an avatar button and profile menu",
"module": "dist/myuw-profile.min.mjs", "module": "dist/myuw-profile.min.mjs",
"browser": "dist/myuw-profile.min.js", "browser": "dist/myuw-profile.min.js",
"scripts": { "scripts": {
"build": "rollup -c", "build": "rollup -c",
"watch": "rollup -c -w", "watch": "rollup -c -w",
"serve": "live-server", "serve": "live-server --port=4200",
"start": "run-p watch serve", "start": "run-p watch serve",
"prepare": "npm run build", "prepare": "npm run build",
"pages": "rm -rf demo && mkdir -p demo && cp -r dist demo/ && cp -r test demo/ && cp index.html demo/ && gh-pages -d demo --repo git@github.com:myuw-web-components/myuw-profile.git", "pages": "rm -rf demo && mkdir -p demo && cp -r dist demo/ && cp -r test demo/ && cp index.html demo/ && gh-pages -d demo --repo git@github.com:myuw-web-components/myuw-profile.git",
...@@ -15,19 +15,18 @@ ...@@ -15,19 +15,18 @@
}, },
"repository": { "repository": {
"type": "git", "type": "git",
"url": "git+https://github.com/myuw-web-components/myuw-profile.git" "url": "git+https://git.doit.wisc.edu/adi-ia/enrollment-profile.git"
}, },
"author": "", "author": "",
"license": "Apache-2.0", "license": "Apache-2.0",
"bugs": {
"url": "https://github.com/myuw-web-components/myuw-profile/issues"
},
"homepage": "https://github.com/myuw-web-components/myuw-profile#readme",
"devDependencies": { "devDependencies": {
"@babel/core": "^7.1.2",
"@babel/preset-env": "^7.1.0",
"gh-pages": "^1.2.0", "gh-pages": "^1.2.0",
"live-server": "^1.2.0", "live-server": "^1.2.0",
"npm-run-all": "^4.1.3", "npm-run-all": "^4.1.3",
"rollup": "^0.63.4", "rollup": "^0.63.4",
"rollup-plugin-babel": "^4.0.3",
"rollup-plugin-html": "^0.2.1", "rollup-plugin-html": "^0.2.1",
"rollup-plugin-minify-es": "^1.1.1", "rollup-plugin-minify-es": "^1.1.1",
"tota11y": "^0.1.6" "tota11y": "^0.1.6"
......
import { rollup } from 'rollup'; import { rollup } from 'rollup';
import html from 'rollup-plugin-html'; import html from 'rollup-plugin-html';
import minify from 'rollup-plugin-minify-es'; import minify from 'rollup-plugin-minify-es';
import babel from 'rollup-plugin-babel';
let fileName = 'myuw-profile'; let fileName = 'myuw-profile';
let objName = 'MyUWProfile'; let objName = 'MyUWProfile';
...@@ -38,7 +39,7 @@ let plugins = { ...@@ -38,7 +39,7 @@ let plugins = {
export default [ export default [
{ {
input: `src/${fileName}.js`, input: `src/${fileName}.js`,
plugins: plugins.full, plugins: plugins.full.concat([babel({exclude: 'node_modules/**'})]),
output: { output: {
file: `dist/${fileName}.js`, file: `dist/${fileName}.js`,
name: objName, name: objName,
...@@ -47,7 +48,7 @@ export default [ ...@@ -47,7 +48,7 @@ export default [
}, },
{ {
input: `src/${fileName}.js`, input: `src/${fileName}.js`,
plugins: plugins.min, plugins: plugins.min.concat([babel({exclude: 'node_modules/**'})]),
output: { output: {
file: `dist/${fileName}.min.js`, file: `dist/${fileName}.min.js`,
name: objName, name: objName,
......
{
"presets": [
["@babel/env", {
"modules": false
}]
],
}
...@@ -19,12 +19,14 @@ class MyUWProfile extends HTMLElement { ...@@ -19,12 +19,14 @@ class MyUWProfile extends HTMLElement {
]; ];
} }
attributeChangedCallback(name, oldValue, newValue){ attributeChangedCallback(name, oldValue, newValue) {
if (typeof this.$circle !== 'undefined') {
// Update the attribute internally // Update the attribute internally
this[name] = newValue; this[name] = newValue;
// Update the component with new att value // Update the component with new att value
this.updateAttribute(name); this.updateAttribute(name);
}
} }
connectedCallback(){ connectedCallback(){
......