Skip to content

Commit

Permalink
Merge branch 'dev'
Browse files Browse the repository at this point in the history
  • Loading branch information
exoRift committed Aug 14, 2022
2 parents 7168cbe + 1d48866 commit beab1df
Show file tree
Hide file tree
Showing 7 changed files with 49 additions and 66 deletions.
2 changes: 1 addition & 1 deletion .codeclimate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ checks:
threshold: 25
method-lines:
config:
threshold: 30
threshold: 50
plugins:
eslint:
enabled: true
Expand Down
60 changes: 25 additions & 35 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,21 @@ on:
release:
types:
- created
workflow_dispatch:

jobs:
storybook:
name: Update Storybook

environment:
name: github-pages
url: ${{ steps.deploy.outputs.page_url }}

strategy:
matrix:
os: [ubuntu-latest]
node: [16]
packager: [npm]

runs-on: ${{ matrix.os }}

Expand All @@ -28,74 +34,58 @@ jobs:
steps:
- uses: actions/checkout@v3
- name: Set up Node
id: setup
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}
- name: Cache Dependencies
id: dep-cache
uses: actions/cache@v3
env:
cache-name: dep-cache
with:
path: |
**/node_modules/
~/.npm/
key: ${{ matrix.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- name: Install Dependencies
run: npm ci
if: steps.dep-cache.outputs.cache-hit != 'true'
cache: ${{ matrix.packager }}
- name: Setup Pages
uses: actions/configure-pages@v1
- name: Install Dependencies
run: npm ci
if: steps.setup.outputs.cache-hit != true
- name: Build Resources
run: npm run build-storybook
- name: Upload Artifact
- name: Upload Static Artifact
uses: actions/upload-pages-artifact@v1
with:
path: './storybook/'
- name: Deploy Storybook to Github Pages
id: deploy
uses: actions/deploy-pages@main


publish:
package:
name: Publish to NPM

if: ${{ github.event_name == 'release' }}

strategy:
matrix:
os: [ubuntu-latest]
node: [16]
packager: [npm]

runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v3
- name: Set up Node
id: setup
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}
- name: Cache Dependencies
id: dep-cache
uses: actions/cache@v3
env:
cache-name: dep-cache
with:
path: |
**/node_modules/
~/.npm/
key: ${{ matrix.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
cache: ${{ matrix.packager }}
- name: Install Dependencies
run: npm ci
if: steps.dep-cache.outputs.cache-hit != 'true'
if: steps.setup.outputs.cache-hit != true
- name: Build Resources
run: npm run build
- name: Publish to NPM
uses: JS-DevTools/npm-publish@v1
with:
token: ${{ secrets.NPM_TOKEN }}
- name: Upload Package Artifact
uses: actions/upload-artifact@v3
with:
name: build
path: './dist/'
32 changes: 9 additions & 23 deletions .github/workflows/quality_assurance.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ name: Quality Assurance
on:
push:
branches:
- master
- dev
- '*'
- '!gh-pages'
pull_request:
branches:
- '*'
Expand All @@ -17,33 +17,22 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
node: [16]
node: [16, lts/*]
packager: [npm]

runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v3
- name: Set up Node
id: setup
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node }}
- name: Cache Dependencies
id: dep-cache
uses: actions/cache@v3
env:
cache-name: dep-cache
with:
path: |
**/node_modules/
~/.npm/
key: ${{ matrix.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
cache: ${{ matrix.packager }}
- name: Install Dependencies
run: npm ci
if: steps.dep-cache.outputs.cache-hit != 'true'
if: steps.setup.outputs.cache-hit != true
- name: Lint Code
run: npm run lint
analyze:
Expand All @@ -52,8 +41,7 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest]
node: [16]
language: [ 'javascript' ]
language: [javascript]

runs-on: ${{ matrix.os }}

Expand All @@ -64,11 +52,9 @@ jobs:

steps:
- uses: actions/checkout@v3

- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
uses: github/codeql-action/analyze@v2
4 changes: 2 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@ node_modules/
.env

# Build folder
build/
playground/
dist/
storybook/
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
![Banner](assets/banner.png)

[![NPM](https://img.shields.io/npm/v/react-fluent-mobile?style=for-the-badge)](https://www.npmjs.com/package/react-fluent-mobile)
[![NPM](https://img.shields.io/npm/v/react-fluent-mobile?style=for-the-badge&color=ed3e3e&logo=npm)](https://www.npmjs.com/package/react-fluent-mobile)
[![Storybook](https://img.shields.io/badge/TRY%20IT%20OUT-STORYBOOK-ff69b4?style=for-the-badge&logo=storybook)](https://exorift.github.io/react-fluent-mobile?path=/story/tutorials--selection&panel=false)
[![Gitter](https://img.shields.io/badge/CHAT%20WITH%20US-GITTER-f68d42?style=for-the-badge&logo=gitter)](https://gitter.im/exoRift/react-fluent-mobile)
[![Roadmap](https://img.shields.io/badge/ROADMAP-GITHUB%20PROJECT-2d85e3?style=for-the-badge&logo=trello)](https://github.com/users/exoRift/projects/2/views/4)

[![Maintainability](https://api.codeclimate.com/v1/badges/a6122e76dcb42d834772/maintainability)](https://codeclimate.com/github/exoRift/react-fluent-mobile/maintainability)
[![Quality Assurance](https://img.shields.io/github/workflow/status/exoRift/react-fluent-mobile/Quality%20Assurance/master?label=Quality%20Assurance&logo=github)](https://github.com/exoRift/react-fluent-mobile/actions/workflows/quality_assurance.yml)

# *What's the problem with mobile browsers?*
### Mobile web browsers are an adaptation of the PC browsing experience for your mobile device. As a result, many features found on desktop browsers are sloppily implemented in ways that just aren't meant for phones, degrading your browsing experience.
Expand Down
10 changes: 7 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
"name": "react-fluent-mobile",
"version": "0.1.0",
"description": "A series of React mixin modules that augment the mobile user experience",
"main": "build/index.js",
"module": "build/index.esm.js",
"main": "dist/index.js",
"module": "dist/index.esm.js",
"files": [
"build/"
"dist/"
],
"scripts": {
"build": "rollup -c",
Expand Down Expand Up @@ -35,6 +35,10 @@
"last 1 safari version"
]
},
"engines" : {
"npm" : ">=7.0.0",
"node" : ">=16.0.0"
},
"keywords": [
"react",
"nodejs",
Expand Down
4 changes: 3 additions & 1 deletion src/components/SelectionMixin.jsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
import React from 'react'
import PropTypes from 'prop-types'

import { FlexibleRange } from '../util/FlexibleRange.js'
import {
FlexibleRange
} from '../util/FlexibleRange.js'

import '../styles/Selection.css'

Expand Down

0 comments on commit beab1df

Please sign in to comment.