tfs-input 0.9.0 → 0.9.6

Sign up to get free protection for your applications and to get access to all the features.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2024 Farhan Madni
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -37,11 +37,11 @@ const name = ref("");
37
37
 
38
38
  ### Props
39
39
 
40
- | **Prop** |**Type**| **Description** |
41
- | ----------- | ------ | ----------------------------------- |
42
- | `label` | String | Text displayed as a floating label. |
43
- | `val` | String | Bound value for input. |
44
- | `placehold` | String | Placeholder text for input. |
40
+ | **Prop** | **Type** | **Description** |
41
+ | ----------- | -------- | ----------------------------------- |
42
+ | `label` | String | Text displayed as a floating label. |
43
+ | `val` | String | Bound value for input. |
44
+ | `placehold` | String | Placeholder text for input. |
45
45
 
46
46
  ### Emits
47
47
 
package/dist/style.css CHANGED
@@ -1 +1 @@
1
- .contain[data-v-2143fbc4]{position:relative}.inp[data-v-2143fbc4]{background-color:transparent;color:#27272a;border:1px solid #52525b;width:100%;margin:5px 15px;border-radius:8.75px;background:none;padding:12px 16px;font-size:18px}.inp[data-v-2143fbc4]:focus{border:1px solid #2563eb;outline:none}.inp[data-v-2143fbc4]::placeholder,.inp[data-v-2143fbc4]::-webkit-input-placeholder,.inp[data-v-2143fbc4]::-ms-input-placeholder,.inp[data-v-2143fbc4]::-moz-input-placeholder{color:#71717a}.inp[data-v-2143fbc4],.label[data-v-2143fbc4]{transition:color,background-color,border-color .2s ease-out}.label[data-v-2143fbc4]{background-color:transparent;color:#71717a;border:1px solid #52525b;font-size:15px;font-weight:600;padding:0 6px;border-radius:7.25px;position:absolute;top:-12px;left:40px;-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px)}.contain:focus-within .label[data-v-2143fbc4]{color:#2563eb;border:1px solid #2563eb}
1
+ .contain[data-v-3ebac3f7]{position:relative}.inp[data-v-3ebac3f7]{background-color:transparent;color:#27272a;border:1px solid #52525b;width:90%;margin:5px 15px;border-radius:8.75px;background:none;padding:12px 16px;font-size:18px}.inp[data-v-3ebac3f7]:focus{border:1px solid #2563eb;outline:none}.inp[data-v-3ebac3f7]::placeholder,.inp[data-v-3ebac3f7]::-webkit-input-placeholder,.inp[data-v-3ebac3f7]::-ms-input-placeholder,.inp[data-v-3ebac3f7]::-moz-input-placeholder{color:#71717a}.inp[data-v-3ebac3f7],.label[data-v-3ebac3f7]{transition:color,background-color,border-color .2s ease-out}.label[data-v-3ebac3f7]{background-color:transparent;color:#71717a;border:1px solid #52525b;font-size:15px;font-weight:600;padding:0 6px;border-radius:7.25px;position:absolute;top:-12px;left:40px;-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px)}.contain:focus-within .label[data-v-3ebac3f7]{color:#2563eb;border:1px solid #2563eb}
package/dist/tfsInput.js CHANGED
@@ -1,11 +1,12 @@
1
1
  import { openBlock as s, createElementBlock as c, createElementVNode as n, toDisplayString as r } from "vue";
2
- const p = (t, l) => {
2
+ const p = (t, a) => {
3
3
  const e = t.__vccOpts || t;
4
- for (const [a, o] of l)
5
- e[a] = o;
4
+ for (const [l, o] of a)
5
+ e[l] = o;
6
6
  return e;
7
- }, i = { class: "contain" }, u = ["placeholder", "value"], d = { class: "label" }, v = {
8
- __name: "tfsInput",
7
+ }, i = { class: "contain" }, u = ["placeholder", "value"], d = { class: "label" }, _ = {
8
+ name: "tInput"
9
+ }, v = /* @__PURE__ */ Object.assign(_, {
9
10
  props: {
10
11
  label: String,
11
12
  val: String,
@@ -13,19 +14,19 @@ const p = (t, l) => {
13
14
  },
14
15
  emits: ["update:val"],
15
16
  setup(t) {
16
- return (l, e) => (s(), c("div", i, [
17
+ return (a, e) => (s(), c("div", i, [
17
18
  n("input", {
18
19
  class: "inp",
19
20
  name: "text",
20
21
  type: "text",
21
22
  placeholder: t.placehold,
22
23
  value: t.val,
23
- onInput: e[0] || (e[0] = (a) => l.$emit("update:val", a.target.value))
24
+ onInput: e[0] || (e[0] = (l) => a.$emit("update:val", l.target.value))
24
25
  }, null, 40, u),
25
26
  n("label", d, r(t.label), 1)
26
27
  ]));
27
28
  }
28
- }, m = /* @__PURE__ */ p(v, [["__scopeId", "data-v-2143fbc4"]]);
29
+ }), f = /* @__PURE__ */ p(v, [["__scopeId", "data-v-3ebac3f7"]]);
29
30
  export {
30
- m as tInput
31
+ f as default
31
32
  };
@@ -1 +1 @@
1
- (function(t,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(t=typeof globalThis<"u"?globalThis:t||self,e(t["tfs-Input"]={},t.Vue))})(this,function(t,e){"use strict";const a=(n,o)=>{const l=n.__vccOpts||n;for(const[s,u]of o)l[s]=u;return l},i={class:"contain"},c=["placeholder","value"],d={class:"label"},p=a({__name:"tfsInput",props:{label:String,val:String,placehold:String},emits:["update:val"],setup(n){return(o,l)=>(e.openBlock(),e.createElementBlock("div",i,[e.createElementVNode("input",{class:"inp",name:"text",type:"text",placeholder:n.placehold,value:n.val,onInput:l[0]||(l[0]=s=>o.$emit("update:val",s.target.value))},null,40,c),e.createElementVNode("label",d,e.toDisplayString(n.label),1)]))}},[["__scopeId","data-v-2143fbc4"]]);t.tInput=p,Object.defineProperty(t,Symbol.toStringTag,{value:"Module"})});
1
+ (function(e,n){typeof exports=="object"&&typeof module<"u"?module.exports=n(require("vue")):typeof define=="function"&&define.amd?define(["vue"],n):(e=typeof globalThis<"u"?globalThis:e||self,e["tfs-Input"]=n(e.Vue))})(this,function(e){"use strict";const n=(t,o)=>{const l=t.__vccOpts||t;for(const[a,u]of o)l[a]=u;return l},s={class:"contain"},c=["placeholder","value"],i={class:"label"};return n(Object.assign({name:"tInput"},{props:{label:String,val:String,placehold:String},emits:["update:val"],setup(t){return(o,l)=>(e.openBlock(),e.createElementBlock("div",s,[e.createElementVNode("input",{class:"inp",name:"text",type:"text",placeholder:t.placehold,value:t.val,onInput:l[0]||(l[0]=a=>o.$emit("update:val",a.target.value))},null,40,c),e.createElementVNode("label",i,e.toDisplayString(t.label),1)]))}}),[["__scopeId","data-v-3ebac3f7"]])});
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tfs-input",
3
- "version": "0.9.0",
3
+ "version": "0.9.6",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "description": "Customizable Vue input component floating labels for modern UIs.",
@@ -41,7 +41,7 @@
41
41
  ],
42
42
  "repository": {
43
43
  "type": "git",
44
- "url": "git+https://github.com/MFM-347/tfsInput.git"
44
+ "url": "https://github.com/MFM-347/tfsInput.git"
45
45
  },
46
46
  "bugs": {
47
47
  "url": "https://github.com/MFM-347/tfsInput/issues"
package/src/main.js CHANGED
@@ -1,3 +1,3 @@
1
1
  import tInput from "./tfsInput.vue";
2
2
 
3
- export { tInput };
3
+ export default tInput;
package/src/tfsInput.vue CHANGED
@@ -1,3 +1,9 @@
1
+ <script>
2
+ export default {
3
+ name: "tInput",
4
+ };
5
+ </script>
6
+
1
7
  <template>
2
8
  <div class="contain">
3
9
  <input
@@ -11,7 +17,6 @@
11
17
  <label class="label"> {{ label }} </label>
12
18
  </div>
13
19
  </template>
14
-
15
20
  <script setup>
16
21
  defineProps({
17
22
  label: String,
@@ -29,7 +34,7 @@ defineEmits(["update:val"]);
29
34
  background-color: transparent;
30
35
  color: #27272a;
31
36
  border: 1px solid #52525b;
32
- width: 100%;
37
+ width: 90%;
33
38
  margin: 5px 15px;
34
39
  border-radius: 8.75px;
35
40
  background: none;