diff options
Diffstat (limited to 'src/scripts/functionality/view-khatian.ts')
| -rw-r--r-- | src/scripts/functionality/view-khatian.ts | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/src/scripts/functionality/view-khatian.ts b/src/scripts/functionality/view-khatian.ts new file mode 100644 index 0000000..9f35762 --- /dev/null +++ b/src/scripts/functionality/view-khatian.ts @@ -0,0 +1,21 @@ +declare function loadKhatian(): void; + +document.addEventListener("DOMContentLoaded", () => { + const proxiedPost = $.post; + + $.post = function() { + if (arguments[0].startsWith("khDetailsAction_LandInfo.action")) { + const callback = arguments[2]; + arguments[2] = (data: any) => { + callback(data); + const tableElement = document.querySelector("#khdetails > table > tbody > tr > td:nth-child(1) > div:nth-child(5) > table > tbody") as HTMLElement | null; + if (tableElement) { + tableElement.style.height = "auto"; + tableElement.style.width = "100%"; + } + } + } + + return proxiedPost.apply(this, Array.from(arguments) as any); + } +}); |
