minecraft-textures 1.16.2 → 1.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (39) hide show
  1. package/README.md +13 -8
  2. package/dist/index.d.ts +3 -13
  3. package/dist/lib/types.d.ts +13 -0
  4. package/dist/minecraft-textures.js +1 -1
  5. package/dist/textures/1.12.d.ts +3 -0
  6. package/dist/textures/1.12.js +1 -1
  7. package/dist/textures/1.13.d.ts +3 -0
  8. package/dist/textures/1.13.js +1 -1
  9. package/dist/textures/1.14.d.ts +3 -0
  10. package/dist/textures/1.14.js +1 -1
  11. package/dist/textures/1.15.d.ts +3 -0
  12. package/dist/textures/1.15.js +1 -1
  13. package/dist/textures/1.16.d.ts +3 -0
  14. package/dist/textures/1.16.js +1 -1
  15. package/dist/textures/1.17.d.ts +3 -0
  16. package/dist/textures/1.17.js +1 -0
  17. package/dist/textures/1.18.d.ts +3 -0
  18. package/dist/textures/1.18.js +1 -0
  19. package/dist/textures/json/1.12.id.json +2705 -0
  20. package/dist/textures/json/1.12.json +1 -1
  21. package/dist/textures/json/1.13.id.json +3161 -0
  22. package/dist/textures/json/1.13.json +7 -42
  23. package/dist/textures/json/1.14.id.json +3509 -0
  24. package/dist/textures/json/1.14.json +7 -42
  25. package/dist/textures/json/1.15.id.json +3537 -0
  26. package/dist/textures/json/1.15.json +7 -42
  27. package/dist/textures/json/1.16.id.json +3909 -0
  28. package/dist/textures/json/1.16.json +982 -1012
  29. package/dist/textures/json/1.17.id.json +4405 -0
  30. package/dist/textures/json/1.17.json +5505 -0
  31. package/dist/textures/json/1.18.id.json +4409 -0
  32. package/dist/textures/json/1.18.json +5510 -0
  33. package/package.json +15 -11
  34. package/dist/lib/toJson.d.ts +0 -1
  35. package/dist/textures/112.d.ts +0 -9
  36. package/dist/textures/113.d.ts +0 -9
  37. package/dist/textures/114.d.ts +0 -5
  38. package/dist/textures/115.d.ts +0 -5
  39. package/dist/textures/116.d.ts +0 -5
package/README.md CHANGED
@@ -1,14 +1,11 @@
1
1
  # Minecraft Textures
2
- This is a library containing all the textures I use for my generators. You're free to use it so long as you credit me.
2
+ This is a library containing all the textures I use for my generators. **You're free to use it so long as you credit me** (see below).
3
3
 
4
- ### There are 1.12 to 1.16 textures currently available.
5
-
6
- The Minecraft item icons are owned by Mojang AB.
7
- This is not endorsed by Mojang AB.
4
+ There are textures from 1.12 to 1.17 currently available.
8
5
 
9
6
  `npm install minecraft-textures`
10
7
 
11
- #### Example Usage:
8
+ ## Example Usage:
12
9
  ```js
13
10
  import hasVersion from 'minecraft-textures'
14
11
  const version = '1.16'
@@ -17,9 +14,17 @@ if (hasVersion(version)) {
17
14
  }
18
15
  ```
19
16
 
20
- #### Notes
17
+ You can also import the JSON files if you are using Node.js.
18
+
19
+ ## Update Notes
20
+ - When upgrading to 1.17, the file names were updated to be the actual version (i.e. `1.17.ts` rather than `117.ts`)
21
21
  - When upgrading to 1.16, the versions are now dynamically imported. You will need to import the path provided by `byVersion`.
22
22
  - For anyone using the .json files, you can now use something like this:
23
23
  - https://unpkg.com/minecraft-textures/dist/textures/json/1.16.json
24
24
 
25
- ### Created by TheDestruc7i0n
25
+ ## License
26
+ Please credit `destruc7i0n (https://thedestruc7i0n.ca)` if you use this.
27
+
28
+ The Minecraft item icons are owned by Mojang Studios.
29
+
30
+ This project is not affiliated with Mojang Studios.
package/dist/index.d.ts CHANGED
@@ -1,16 +1,6 @@
1
- export interface TexturesType {
2
- comment: string;
3
- items: {
4
- readable: string;
5
- id: string;
6
- texture: string;
7
- }[];
8
- }
9
- declare const textures: {
10
- [key: string]: string;
11
- };
12
- declare const hasVersion: (version: string) => boolean;
1
+ export declare const textures: string[];
13
2
  export declare const versions: string[];
14
3
  export declare const latestVersion: string;
15
- export { textures };
4
+ declare const hasVersion: (version: string) => boolean;
5
+ export * from './lib/types';
16
6
  export default hasVersion;
@@ -1,3 +1,16 @@
1
+ export interface TexturesType {
2
+ comment: string;
3
+ items: Item[];
4
+ }
5
+ export interface TexturesTypeById {
6
+ comment: string;
7
+ items: {
8
+ [id: string]: {
9
+ readable: string;
10
+ texture: string;
11
+ };
12
+ };
13
+ }
1
14
  export interface Item {
2
15
  readable: string;
3
16
  id: string;
@@ -1 +1 @@
1
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports["minecraft-textures"]=t():e["minecraft-textures"]=t()}(window,(function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=5)}({5:function(e,t,n){"use strict";n.r(t),n.d(t,"versions",(function(){return o})),n.d(t,"latestVersion",(function(){return u})),n.d(t,"textures",(function(){return r}));var r={1.12:"112",1.13:"113",1.14:"114",1.15:"115",1.16:"116"},o=Object.keys(r),u=o[o.length-1];t.default=function(e){return Object.keys(r).includes(e)}}})}));
1
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports["minecraft-textures"]=t():e["minecraft-textures"]=t()}(self,(function(){return(()=>{"use strict";var e={d:(t,o)=>{for(var r in o)e.o(o,r)&&!e.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:o[r]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};e.r(t),e.d(t,{textures:()=>o,versions:()=>r,latestVersion:()=>n,default:()=>f});var o=["1.12","1.13","1.14","1.15","1.16","1.17","1.18"],r=o,n=o[o.length-1];const f=function(e){return Object.keys(o).includes(e)};return t})()}));
@@ -0,0 +1,3 @@
1
+ import type { TexturesType } from '../lib/types';
2
+ declare const Textures: TexturesType;
3
+ export default Textures;