Skip to content

Commit

Permalink
updat docs
Browse files Browse the repository at this point in the history
  • Loading branch information
C-o-m-o-n committed Dec 30, 2023
1 parent 9b1ac3c commit a067aab
Show file tree
Hide file tree
Showing 5 changed files with 408 additions and 123 deletions.
342 changes: 252 additions & 90 deletions docs/index.html
Original file line number Diff line number Diff line change
@@ -1,103 +1,114 @@
<!DOCTYPE html>
<!-- <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>TextBin</title>
<link rel="stylesheet" href="style.css">

<link rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/10.0.3/styles/default.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/10.0.3/highlight.min.js"></script>
<script>hljs.initHighlightingOnLoad();</script>
</head>
<body>
<link rel="stylesheet" href="style.css" />
<nav>
<div class="logo">
<img style="height: 90px; width:90px;" src="pytextbin-removebg-preview.png">
</div>
<div class="menu">
<link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/10.0.3/styles/default.min.css"
/>
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/10.0.3/highlight.min.js"></script>
<script>
hljs.initHighlightingOnLoad();
</script>
</head>
<body>
<nav>
<div class="logo">
<img
width="100px"
src="pytextbin-removebg-preview.png"
/>
</div>
<div class="menu">
<div class="link-item">
<a href="#">Home</a>
<a href="#">Home</a>
</div>
<div class="link-item">
<a href="#">Code</a>
<a href="#">Code</a>
</div>
<div class="link-item">
<a href="#">Contribution</a>
<a href="#">Contribution</a>
</div>
<div class="link-item">
<a href="#">More</a>
<a href="#">More</a>
</div>
</div>
</nav>
</div>
</nav>
<div class="header">
<div class="about-textbin">
<h1 style="font-weight: bolder; margin: 3px">welcome to TextBin</h1>
<div class="about-install">
<div class="about-textbin">
<p style="font-weight: bolder; margin:3px;">welcome to TextBin</p>
<p style="color: #81ca4d;"> What is textbin?</p>
<p>Textbin is a Python package that provides text-to-binary and binary-to-text conversion, as well as JSON-to-base64 and base64-to-JSON encoding and decoding.</p>
</div>

<div class="installation">
<p style="font-weight: bolder; margin:3px;">installation</p>
<p style="color: #81ca4d;"> How do I install textbin?</p>
<p>You can install textbin through your terminal using pip from PyPI:<br>
<code style="color: #49daf2;">pip install textbin</code>
</p>
<p>Alternatively, you can find the project on GitHub:
<a href="https://github.com/C-o-m-o-n/textbin">GitHub Repository</a>
</p>
<p>
Textbin is a Python package that provides text-to-binary and
binary-to-text conversion, as well as JSON-to-base64 and
base64-to-JSON encoding and decoding.
</p>
</div>
<div class="installation">
<h2 style="font-weight: bolder; margin: 3px">installation</h2>
<p>
You can install textbin through your terminal using pip from PyPI:<br />
<code style="color: #49daf2">pip install textbin</code>
</p>
<p>
Alternatively, you can find the project on GitHub:
<a href="https://github.com/C-o-m-o-n/textbin">GitHub Repository</a>
</p>
</div>
</div>
<div class="usage">
<h2 style="font-weight: bolder; margin: 3px">Usage</h2>
</div>
<div class="usage">
<p style="font-weight: bolder; margin:3px;">Usage</p>
<p>
To begin, import the textbin module then create an object from the
Textbin() class, which you'll use to access all the methods.
</p>
<div class="instantiate">
<pre>
<code class="python">
# import textbin
from textbin.textbin import *
# create textbin_obj instance
textbin_obj = textbin.Textbin()
</code>
</pre>
</div>
<p style="color: #81ca4d;"> How do I use textbin?</p>

<p>To begin, import the textbin module then create an object from the Textbin() class, which you'll use to access all the methods.</p>
<pre>
<code style="max-width:380px; border-radius: 10px;" class="python">
# import textbin
from textbin.textbin import *
# create textbin_obj instance
textbin_obj = textbin.Textbin()
</code>
</pre>

<div class="code-area">


<!-- Text and binary -->
<div class="text-bin">
<p style="color: #81ca4d;margin: 3px;">Text and Binary</p>
<pre>
<code style="max-width:380px; border-radius: 10px;" class="python">
<div class="code-area">
Text and binary
<div class="text-bin">
<p style="color: #81ca4d; margin: 3px">Text and Binary</p>
<pre>
<code class="python">
from textbin.textbin import *
textbin_obj = textbin.Textbin()
# Convert text to binary
word = "hello"
converted_word = textbin_obj.to_binary(word)
print(converted_word) #Output: 1101000 1100101 1101100 1101100 1101111
print(converted_word)
#Output: 1101000 1100101 1101100 1101100 1101111
# Convert binary to text
binary = "1101000 1100101 1101100 1101100 1101111"
converted_binary = textbin_obj.to_text(binary)
print(converted_binary) # Output: hello
</code>
</pre>

</div>
<!-- Text and binary end -->

<!-- JSON and Base64-->
<div class="json-base">
<p style="color: #81ca4d;margin: 3px;">JSON and Base64</p>
<pre>
</div>
Text and binary end
JSON and Base64
<div class="json-base">
<p style="color: #81ca4d; margin: 3px">JSON and Base64</p>
<pre>
<code style="max-width:380px; border-radius: 10px;" class="python">
from textbin.textbin import *
textbin_obj = textbin.Textbin()
Expand All @@ -113,32 +124,183 @@
print(converted_binary) # Output: {'foo': 'bar'}
</code>
</pre>
</div>
JSON and Base64 end
</div>
</div>
<div class="inside-textbin">
<p style="font-weight: bolder; margin: 3px">Inside textbin</p>
<p style="color: #81ca4d">What does it look like inside textbin?</p>
<p>
Inside the textbin.py, there is a 'Textbin()' class which has the
methods:
</p>
<ul>
<li>
<span style="color: #81ca4d; font-weight: bolder">to_binary</span>:
Converts text to binary representation.
</li>
<li>
<span style="color: #81ca4d; font-weight: bolder">to_text</span>:
Converts binary representation to text.
</li>
<li>
<span style="color: #81ca4d; font-weight: bolder">json_to_base64</span
>: Converts a JSON object to a base64-encoded string.
</li>
<li>
<span style="color: #81ca4d; font-weight: bolder">base64_to_json</span
>: Converts a base64-encoded string to a JSON object.
</li>
<li>
<span style="color: #81ca4d; font-weight: bolder">csv_to_json</span>:
Converts a CSV string to a JSON object.
</li>
<li>
<span style="color: #81ca4d; font-weight: bolder">json_to_csv</span>:
Converts a JSON object to a CSV string.
</li>
</ul>
</div>
<h1>Note!! The docs is still under development. Check again soon.</h1>
<h1>Help us develop it faster.</h1>
</body>
</html>
-->

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>PyTextBin</title>
<link rel="stylesheet" href="style.css" />

<body>
<header>
<img src="pytextbin-removebg-preview.png" alt="Profile Picture">
<h1>PyTextBin-0.0.3</h1>
<h2>pip install PyTextBin-0.0.3</h2>
<h3>pip install PyTextBin-0.0.3</h3>
</header>

<main>
<section id="about">
<h2 class="section-title">About PyTextBin</h2>
<p>
Textbin is a Python package that provides text-to-binary and
binary-to-text conversion, as well as JSON-to-base64 and
base64-to-JSON encoding and decoding.
</p>
</section>

<section id="experience">
<h2 class="section-title">Usage</h2>
<p>Inside the textbin.py, there is a 'Textbin()' class which has the methods:</p>
<ul>
<li>to_binary: Converts text to binary representation.</li>
<li>to_text: Converts binary representation to text.</li>
<li>json_to_base64: Converts a JSON object to a base64-encoded string.</li>
<li>base64_to_json: Converts a base64-encoded string to a JSON object.</li>
<li>csv_to_json: Converts a CSV string to a JSON object.</li>
<li>json_to_csv: Converts a JSON object to a CSV string.</li>
<li>xml_to_json: Converts an XML string to a JSON object</li>
<li>json_to_xml: Converts a JSON object to an XML string</li>
<li>xml_to_csv: Converts an XML string to a CSV file.</li>
</ul>

To begin, import the pytextbin module then create an object from the
Textbin() class, which you'll use to access all the methods.
<pre>
<code class="python">
# import textbin
from textbin.textbin import *
# create textbin_obj instance
textbin_obj = textbin.Textbin()
</code>
</pre>
</section>

<section id="skills">
<h2 class="section-title">Skills</h2>
<ul>
<li>Full Stack Developement</li>
<li>Open-Source contributor</li>
<li>React JS</li>
<li>Nextjs</li>
<li>Node JS</li>
<li>React-Native</li>
<li>Django</li>
<li>Flask</li>
<li>Robotics and IOT</li>
</ul>
</section>

<section id="interests">
<h2 class="section-title">Interests</h2>
<ul>
<li>Learning new things</li>
<li>Watching movies</li>
<li>Reading</li>
<li>Listening to music</li>
<li>Playing video games</li>
<li>Writing Code</li>

</div>
<!-- JSON and Base64 end-->
</ul>
</section>

<section id="call-to-action">
<h2 class="section-title">Get in Touch</h2>
<div class="socials">
<div class="left">
<div>
<svg xmlns="http://www.w3.org/2000/svg" height="16" width="15.5" viewBox="0 0 496 512"><!--!Font Awesome Free 6.5.1 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free Copyright 2023 Fonticons, Inc.--><path d="M165.9 397.4c0 2-2.3 3.6-5.2 3.6-3.3 .3-5.6-1.3-5.6-3.6 0-2 2.3-3.6 5.2-3.6 3-.3 5.6 1.3 5.6 3.6zm-31.1-4.5c-.7 2 1.3 4.3 4.3 4.9 2.6 1 5.6 0 6.2-2s-1.3-4.3-4.3-5.2c-2.6-.7-5.5 .3-6.2 2.3zm44.2-1.7c-2.9 .7-4.9 2.6-4.6 4.9 .3 2 2.9 3.3 5.9 2.6 2.9-.7 4.9-2.6 4.6-4.6-.3-1.9-3-3.2-5.9-2.9zM244.8 8C106.1 8 0 113.3 0 252c0 110.9 69.8 205.8 169.5 239.2 12.8 2.3 17.3-5.6 17.3-12.1 0-6.2-.3-40.4-.3-61.4 0 0-70 15-84.7-29.8 0 0-11.4-29.1-27.8-36.6 0 0-22.9-15.7 1.6-15.4 0 0 24.9 2 38.6 25.8 21.9 38.6 58.6 27.5 72.9 20.9 2.3-16 8.8-27.1 16-33.7-55.9-6.2-112.3-14.3-112.3-110.5 0-27.5 7.6-41.3 23.6-58.9-2.6-6.5-11.1-33.3 2.6-67.9 20.9-6.5 69 27 69 27 20-5.6 41.5-8.5 62.8-8.5s42.8 2.9 62.8 8.5c0 0 48.1-33.6 69-27 13.7 34.7 5.2 61.4 2.6 67.9 16 17.7 25.8 31.5 25.8 58.9 0 96.5-58.9 104.2-114.8 110.5 9.2 7.9 17 22.9 17 46.4 0 33.7-.3 75.4-.3 83.6 0 6.5 4.6 14.4 17.3 12.1C428.2 457.8 496 362.9 496 252 496 113.3 383.5 8 244.8 8zM97.2 352.9c-1.3 1-1 3.3 .7 5.2 1.6 1.6 3.9 2.3 5.2 1 1.3-1 1-3.3-.7-5.2-1.6-1.6-3.9-2.3-5.2-1zm-10.8-8.1c-.7 1.3 .3 2.9 2.3 3.9 1.6 1 3.6 .7 4.3-.7 .7-1.3-.3-2.9-2.3-3.9-2-.6-3.6-.3-4.3 .7zm32.4 35.6c-1.6 1.3-1 4.3 1.3 6.2 2.3 2.3 5.2 2.6 6.5 1 1.3-1.3 .7-4.3-1.3-6.2-2.2-2.3-5.2-2.6-6.5-1zm-11.4-14.7c-1.6 1-1.6 3.6 0 5.9 1.6 2.3 4.3 3.3 5.6 2.3 1.6-1.3 1.6-3.9 0-6.2-1.4-2.3-4-3.3-5.6-2z"/></svg>
<a href="https://github.com/C-o-m-o-n">Github </a>
</div>

<div>
<svg xmlns="http://www.w3.org/2000/svg" height="16" width="14" viewBox="0 0 448 512"><!--!Font Awesome Free 6.5.1 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free Copyright 2023 Fonticons, Inc.--><path d="M64 32C28.7 32 0 60.7 0 96V416c0 35.3 28.7 64 64 64H384c35.3 0 64-28.7 64-64V96c0-35.3-28.7-64-64-64H64zm297.1 84L257.3 234.6 379.4 396H283.8L209 298.1 123.3 396H75.8l111-126.9L69.7 116h98l67.7 89.5L313.6 116h47.5zM323.3 367.6L153.4 142.9H125.1L296.9 367.6h26.3z"/></svg>
<a href="https://x.com/C_o_m_o_n">Twitter</a>
</div>


<div>
<svg xmlns="http://www.w3.org/2000/svg" height="16" width="18" viewBox="0 0 576 512"><!--!Font Awesome Free 6.5.1 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free Copyright 2023 Fonticons, Inc.--><path d="M288 64C64 64 0 160 0 272S80 448 176 448h8.4c24.2 0 46.4-13.7 57.2-35.4l23.2-46.3c4.4-8.8 13.3-14.3 23.2-14.3s18.8 5.5 23.2 14.3l23.2 46.3c10.8 21.7 33 35.4 57.2 35.4H400c96 0 176-64 176-176s-64-208-288-208zM96 256a64 64 0 1 1 128 0A64 64 0 1 1 96 256zm320-64a64 64 0 1 1 0 128 64 64 0 1 1 0-128z"/></svg>
<a href="https://devpost.com/C-o-m-o-n">Devpost</a>
</div>
</div>

</div>
<div class="right">
<div>
<svg xmlns="http://www.w3.org/2000/svg" height="16" width="20" viewBox="0 0 640 512"><!--!Font Awesome Free 6.5.1 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free Copyright 2023 Fonticons, Inc.--><path d="M524.5 69.8a1.5 1.5 0 0 0 -.8-.7A485.1 485.1 0 0 0 404.1 32a1.8 1.8 0 0 0 -1.9 .9 337.5 337.5 0 0 0 -14.9 30.6 447.8 447.8 0 0 0 -134.4 0 309.5 309.5 0 0 0 -15.1-30.6 1.9 1.9 0 0 0 -1.9-.9A483.7 483.7 0 0 0 116.1 69.1a1.7 1.7 0 0 0 -.8 .7C39.1 183.7 18.2 294.7 28.4 404.4a2 2 0 0 0 .8 1.4A487.7 487.7 0 0 0 176 479.9a1.9 1.9 0 0 0 2.1-.7A348.2 348.2 0 0 0 208.1 430.4a1.9 1.9 0 0 0 -1-2.6 321.2 321.2 0 0 1 -45.9-21.9 1.9 1.9 0 0 1 -.2-3.1c3.1-2.3 6.2-4.7 9.1-7.1a1.8 1.8 0 0 1 1.9-.3c96.2 43.9 200.4 43.9 295.5 0a1.8 1.8 0 0 1 1.9 .2c2.9 2.4 6 4.9 9.1 7.2a1.9 1.9 0 0 1 -.2 3.1 301.4 301.4 0 0 1 -45.9 21.8 1.9 1.9 0 0 0 -1 2.6 391.1 391.1 0 0 0 30 48.8 1.9 1.9 0 0 0 2.1 .7A486 486 0 0 0 610.7 405.7a1.9 1.9 0 0 0 .8-1.4C623.7 277.6 590.9 167.5 524.5 69.8zM222.5 337.6c-29 0-52.8-26.6-52.8-59.2S193.1 219.1 222.5 219.1c29.7 0 53.3 26.8 52.8 59.2C275.3 311 251.9 337.6 222.5 337.6zm195.4 0c-29 0-52.8-26.6-52.8-59.2S388.4 219.1 417.9 219.1c29.7 0 53.3 26.8 52.8 59.2C470.7 311 447.5 337.6 417.9 337.6z"/></svg>
<a href="https://discord.gg/eqSU46Y7xW">Discord</a>
</div>
<div>

<svg xmlns="http://www.w3.org/2000/svg"
height="16" width="14" viewBox="0 0 448 512">
<!--!Font Awesome Free 6.5.1 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free Copyright 2023 Fonticons, Inc.-->
<path d="M416 32H31.9C14.3 32 0 46.5 0 64.3v383.4C0 465.5 14.3 480 31.9 480H416c17.6 0 32-14.5 32-32.3V64.3c0-17.8-14.4-32.3-32-32.3zM135.4 416H69V202.2h66.5V416zm-33.2-243c-21.3 0-38.5-17.3-38.5-38.5S80.9 96 102.2 96c21.2 0 38.5 17.3 38.5 38.5 0 21.3-17.2 38.5-38.5 38.5zm282.1 243h-66.4V312c0-24.8-.5-56.7-34.5-56.7-34.6 0-39.9 27-39.9 54.9V416h-66.4V202.2h63.7v29.2h.9c8.9-16.8 30.6-34.5 62.9-34.5 67.2 0 79.7 44.3 79.7 101.9V416z"/>
</svg>
<a href="https://linkedin.com/in/c-o-m-o-n">LinkedIn</a>
</div>

</div>
<div>

<div class="inside-textbin">
<p style="font-weight: bolder; margin:3px;">Inside textbin</p>
<p style="color: #81ca4d;">What does it look like inside textbin?</p>
<p>Inside the textbin.py, there is a 'Textbin()' class which has the methods:</p>
<ul>
<li><span style="color: #81ca4d; font-weight: bolder;">to_binary</span>: Converts text to binary representation.</li>
<li><span style="color: #81ca4d; font-weight: bolder;">to_text</span>: Converts binary representation to text.</li>
<li><span style="color: #81ca4d; font-weight: bolder;">json_to_base64</span>: Converts a JSON object to a base64-encoded string.</li>
<li><span style="color: #81ca4d; font-weight: bolder;">base64_to_json</span>: Converts a base64-encoded string to a JSON object.</li>
<li><span style="color: #81ca4d; font-weight: bolder;">csv_to_json</span>: Converts a CSV string to a JSON object.</li>
<li><span style="color: #81ca4d; font-weight: bolder;">json_to_csv</span>: Converts a JSON object to a CSV string.</li>
</ul>
</div>
<svg xmlns="http://www.w3.org/2000/svg" height="16" width="16" viewBox="0 0 512 512"><!--!Font Awesome Free 6.5.1 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free Copyright 2023 Fonticons, Inc.--><path d="M352 256c0 22.2-1.2 43.6-3.3 64H163.3c-2.2-20.4-3.3-41.8-3.3-64s1.2-43.6 3.3-64H348.7c2.2 20.4 3.3 41.8 3.3 64zm28.8-64H503.9c5.3 20.5 8.1 41.9 8.1 64s-2.8 43.5-8.1 64H380.8c2.1-20.6 3.2-42 3.2-64s-1.1-43.4-3.2-64zm112.6-32H376.7c-10-63.9-29.8-117.4-55.3-151.6c78.3 20.7 142 77.5 171.9 151.6zm-149.1 0H167.7c6.1-36.4 15.5-68.6 27-94.7c10.5-23.6 22.2-40.7 33.5-51.5C239.4 3.2 248.7 0 256 0s16.6 3.2 27.8 13.8c11.3 10.8 23 27.9 33.5 51.5c11.6 26 20.9 58.2 27 94.7zm-209 0H18.6C48.6 85.9 112.2 29.1 190.6 8.4C165.1 42.6 145.3 96.1 135.3 160zM8.1 192H131.2c-2.1 20.6-3.2 42-3.2 64s1.1 43.4 3.2 64H8.1C2.8 299.5 0 278.1 0 256s2.8-43.5 8.1-64zM194.7 446.6c-11.6-26-20.9-58.2-27-94.6H344.3c-6.1 36.4-15.5 68.6-27 94.6c-10.5 23.6-22.2 40.7-33.5 51.5C272.6 508.8 263.3 512 256 512s-16.6-3.2-27.8-13.8c-11.3-10.8-23-27.9-33.5-51.5zM135.3 352c10 63.9 29.8 117.4 55.3 151.6C112.2 482.9 48.6 426.1 18.6 352H135.3zm358.1 0c-30 74.1-93.6 130.9-171.9 151.6c25.5-34.2 45.2-87.7 55.3-151.6H493.4z"/></svg>
<a href="https://my-portfolio-3f43b.web.app/">Website</a>
</div>
</div>


</div>
</section>
</main>

<h1>Note!! The docs is still under development. Check again soon. </h1>
<h1>Help us develop it faster. </h1>
<footer>
<p>&copy; 2023 Collins | Inspired by TechLit Africa</p>
</footer>
</body>
</html>
Loading

0 comments on commit a067aab

Please sign in to comment.