From e50b2af5d5143aea88860cfd1f915e3ecaed4abe Mon Sep 17 00:00:00 2001 From: Ben McLean Date: Fri, 3 May 2024 23:38:46 +1000 Subject: [PATCH] Add documentation --- .github/workflows/pkl | 2 +- LICENSE.md | 22 ++++++++++++++++++++++ README.md | 22 +++++++++++++++++++++- 3 files changed, 44 insertions(+), 2 deletions(-) create mode 100644 LICENSE.md diff --git a/.github/workflows/pkl b/.github/workflows/pkl index c62e19e..7cfd3a2 160000 --- a/.github/workflows/pkl +++ b/.github/workflows/pkl @@ -1 +1 @@ -Subproject commit c62e19eb3f3eff5f0adabccb943ed053248d7c00 +Subproject commit 7cfd3a27622daca60e072b4638c9fad91477026e diff --git a/LICENSE.md b/LICENSE.md new file mode 100644 index 0000000..45930ce --- /dev/null +++ b/LICENSE.md @@ -0,0 +1,22 @@ + +The MIT License (MIT) + +Copyright (c) 2024 Emily McLean + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md index 1132d8b..11be0c1 100644 --- a/README.md +++ b/README.md @@ -1 +1,21 @@ -# ContrastAccessibility +# Contrast Accessibility +[![Build](https://github.com/BenMMcLean/contrast-accessibility/actions/workflows/build.yml/badge.svg)](https://github.com/BenMMcLean/contrast-accessibility/actions/workflows/build.yml) +[![Lint](https://github.com/BenMMcLean/contrast-accessibility/actions/workflows/lint.yml/badge.svg)](https://github.com/BenMMcLean/contrast-accessibility/actions/workflows/lint.yml) +[![Test](https://github.com/BenMMcLean/contrast-accessibility/actions/workflows/test.yml/badge.svg)](https://github.com/BenMMcLean/contrast-accessibility/actions/workflows/test.yml) + +A library providing the famous ["human readable bytes" StackOverflow answer](https://stackoverflow.com/questions/3758606/how-can-i-convert-byte-size-into-a-human-readable-format-in-java). + +## Installation +![Stable](https://img.shields.io/github/v/release/BenMMcLean/contrast-accessibility?label=Stable) +![Preview](https://img.shields.io/github/v/release/BenMMcLean/contrast-accessibility?label=Preview&include_prereleases) + +``` +implementation "cl.emilym:contrast-accessibility:" +``` + +## Usage +```java +long color1 = 0xFF0000; // Red +long color2 = 0x000000; // Black +System.out.println(ContrastAccessibility.valid(color1, color2)); // True +``` \ No newline at end of file